I’m working on a component installer (only for Delphi XE2) and I would like to detect if the Delphi XE2 IDE is running. How would you detect it?
P.S. I know about the TAppBuilder window class name, but I need to detect also the IDE version.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
These are the steps to determine if the Delphi XE2 is running
1) First Read the location of the the bds.exe file from the
Appentry in the\Software\Embarcadero\BDS\9.0registry key which can be located in the HKEY_CURRENT_USER or HKEY_LOCAL_MACHINE Root key.2) Then using the CreateToolhelp32Snapshot function you can check if exist a exe with the same name running.
3) Finally using the PID of the last processed entry you can resolve the full file path of the Exe (using the
GetModuleFileNameExfunction) and then compare the names again.Check this sample code
Addtional resources.
Detecting installed delphi versions