Finding GUIDs with GExperts Grep

 Delphi  Comments Off on Finding GUIDs with GExperts Grep
Feb 162019

I recently had a problem with access violations when calling methods of interfaces. The reason turned out to be duplicate GUIDs in the interface declarations. This caused AVs because the wrong methods were called and the parameters passed to them were not of the right type and numbers. Duplicate GUIDs are usually caused by copying existing interfaces and changing them, without also generating a GUID for the copy. (Btw: The Hotkey for generating a new GUID in the Delphi IDE is Ctrl+Shift+G.)

So I looked for a way to find all interfaces and their GUIDs in my program. There is a uInterfaces.Duplicates unit on GitHub which claims to retrieve this list. Unfortunately I needed this for a Delphi 2007 program and Delphi 2007 does not come with a System.RTTI unit, so this was not an option (and therefore I don’t know whether this unit would have worked).

StackOverflow didn’t help much either, apart from David Heffernan’s suggestion to parse the source code.

So this is what I did. I used GExperts Grep to search for GUIDs, or more eaxct: For the pattern that is used to add a GUID to an interface declaration in Delphi.

It always looks like this:

  ISomeInterface = interface ['{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}'];

Where X is a hexadecimal digit in upper case.

The Regular Expression for this is:


The literals [ ] and { } must be escaped with a backslash because they have special meaning in a RegEx. [0-9A-F] means one of ‘0’..’9′ or ‘A’..’F’ which is an upper case hexadecimal digit. {4} means four of those {8} means eight and of course {12} means twelve.

You have to turn off the option “Whole Word” and turn on “Regular Expression”. Of course this needs to search at least all files in the project.

Why do I say “at least”? Because actually it needs to search all files linked into the project, including any packages if such are used. “All files in project” only searches files listed in the DPR file, so it’s potentially missing quite a lot.

Which, again, reminds me that I wanted to extend Grep Search to search all files in the MAP file. Code for getting that list is already in place and being used e.g. in the Open File Expert. I “just” need to put the pieces together.

I’m thinking about making yet another Expert out of this, that not only lists all GUIDs but shows a list of Interface names and their associated GUIDs and of course checks for duplicates.

Discussion about this post in the international Delphi Praxis forum.

 Posted by on 2019-02-16 at 12:28

Delphi Blogs

 Delphi  Comments Off on Delphi Blogs
Feb 102019

The Delphi Wiki has a list of “Useful Sites” which has a sub section for Delphi Blogs.

I have just further divided that section into:

  • Active Blogs, which contains blogs that are active
  • Intensive Care Unit, which contains blogs that are still available but have been inactive for more than a year
  • Cemetery, which contains blogs that are dead, so I have changed the link to point to the last snapshot in the Internet Archive.

If you find your blog in one of the later ones and it is still active (maybe moved to a new url), feel free to edit the page again. It’s a Wiki after all.

I have also added the
Delphi Praxis international developer community and the new
Embarcadero Discussion Forum (Delphi) to the list of Web Based Forums and removed some outdated links.

 Posted by on 2019-02-10 at 15:53

Two GExperts bugs fixed, 14 to go

 Delphi, GExperts  Comments Off on Two GExperts bugs fixed, 14 to go
Feb 092019

I just fixed two (newly reported) bugs in GExperts:

  1. The Set Tab Order dialog no longer worked in Delphi 6, 7 and 2005. This was due to me adding AlignWithMargins (and the associated Margins property) to the dfm file. This property apparently was introduced in Delphi 2006. Again, this underlines what I mentioned several times: I do not use Delphi < 2007 for anything but testing and fixing bugs GExperts. That’s why glitches like this tend to slip by unnoticed. That’s why I would like people to volunteer for testing the various versions. But apparently nobody can be bothered. Fine by me, but you will have to live with the consequences. I don’t have a QA department.
  2. The extensions to the Uses Clause Manager caused several thousand (small) files to be created in the GExperts configuration directory. This directory is located under AppData\roaming\GExperts which means it will be copied when roaming profiles are enabledin a Windows domain. I didn’t know that anybody still uses roaming profiles since they are usually not worth the trouble, but apparently they are still being used. So I now moved that cache to AppData\local and also added a config option to disable caching altogether.

There are now 14 open bug reports on SourceForge. But if you encounter more, please do report them there!

There is no release yet and it might take a while until I feel like doing one, but you can always compile your own GExperts DLL. Make sure you delete the existing directory AppData\roaming\GExperts\DelphiXXX\UsesExpertCache when you replace the DLL with the new one.

btw: Did you notice that I have added menus to my blog?

Discussion about this post in the international Delphi Praxis forum.

 Posted by on 2019-02-09 at 17:22

Installing Webmin on Ubuntu 18.04 Server

 Linux  Comments Off on Installing Webmin on Ubuntu 18.04 Server
Feb 062019

I just tried to install Webmin on a fresh install of Ubuntu 18.04 Server in the same way as I did on 16.04. Unfortunately it failed on the command

apt install webmin

because the package apt-show-versions was not found. I solved this by adding the universe repository to apt with

sudo add-apt-repository universe

After this change it worked as expected.

Just in case somebody else is also missing the text editor e3 in Ubuntu 18.04 Server: It’s also in the universe repository.

 Posted by on 2019-02-06 at 13:55

Google✝ is dead

 blog, Google  Comments Off on Google✝ is dead
Feb 032019

OK, most of you already knew that. I am writing this only because I will now stop posting there. Not just the automatic posts generated by this blog, but also my personal posts.


(Picture taken from Jürgen Christoffel’s G+ post.)

I considered migrating my content from G ✝ to somewhere else (e.g. yet another WordPress blog under .dummzeuch.de, I tried it, it worked), but I decided that it isn’t worth the effort. So, bye bye Google+, it was great as long as it lasted.

If you want to continue following me, consider one of the options listed here.

And one last word to You, Google: I will remember what you did. I will never again trust you.

Btw: Did you know that they will also kill Hangouts?

 Posted by on 2019-02-03 at 12:47

Sie wollen mich einstellen?

 Delphi  Comments Off on Sie wollen mich einstellen?
Jan 272019

Derzeit habe ich eine unbefristete Vollzeitstelle (40h) als Leiter der Softwareentwicklung bei der TÜV Rheinland Schniering GmbH. Ich bin damit ganz zufrieden und suche nicht aktiv nach einer neuen Stelle.

Da ich aber immer wieder mal gefragt werde, ob ich an einem Angebot Interesse habe, stelle ich hier auf, was man mir bieten müsste, damit ich über einen Wechsel nachdenke.

 Posted by on 2019-01-27 at 15:24

RDP Wrapper Library

 Delphi  Comments Off on RDP Wrapper Library
Jan 272019

I need to check this out:

The goal of the RDP Wrapper Library project is to enable Remote Desktop Host support and concurrent RDP sessions on reduced functionality systems for home usage.

RDP Wrapper works as a layer between Service Control Manager and Terminal Services, so the original termsrv.dll file remains untouched. Also this method is very strong against Windows Update.


 Posted by on 2019-01-27 at 14:34

DeltaChat Messenger

 Android, Linux, Windows  Comments Off on DeltaChat Messenger
Jan 272019

DeltaChat is a messenger that uses email as the transport medium, so potentially almost everybody already has an account for it. Today, a they announced a new release, not only for the existing Android app but also for Desktop (Mac and Linux only so far) and iOS.

I think that is a very interesting project since it does not require yet another central server. It also supports encryption using the Autocrypt Level 1 standard, if both ends use DeltaChat. It is possible to use the same protocol (but without encryption) between DeltaChat and a regular email program.

In my tests with the older Android release it worked well. I created a new email address specifically for DeltaChat. That’s what I would suggest to everybody who wants to use it. I plan to replace Google Hangouts with DeltaChat when Hangouts gets shut down later this year. But I would need a Windows client first.

 Posted by on 2019-01-27 at 13:06

Completely disable Windows 10 telemetry collection

 Windows, Windows 10  Comments Off on Completely disable Windows 10 telemetry collection
Jan 072019

So I don’t forget: According to an article in c’t magazine, disabling the “DiagTrack” service (“Connected User Experience and Telemetry”) will completely disable user tracking in Windows 10. They also say that they did not see any negative effects.

Source: Telefonierverbot in c’t 01/2019 page 172 (in German)

 Posted by on 2019-01-07 at 15:57