using delphi for custom actions - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

CarlAarnes
Posts: 58
Joined: Tue May 24, 2011 3:43 pm

using delphi for custom actions

Hi again,
now im trying to use Delphi (Delphi_2009) to create some custom action, but this seems kinda hard to figure out.

Since i could not find no msi.h translation, I think i must access msi.dll by using a TypeLib in Delphi with dispinterface, I think this basically means using COM to access msiexec server... correct me if im wrong.

Are there any examples on how to do this?

allright i think im getting a bit further, but as im new to using COM this may be completely wrong.

Would this be the correct way to access the session object? ... seems OpenPackage returns session....

oInstaller := CreateComObject(DIID_Installer) as Installer;
oSession := oInstaller.OpenPackage()
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: using delphi for custom actions

Hi Carl,

The following thread from StackOverflow should give you some pointers.

Best regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
CarlAarnes
Posts: 58
Joined: Tue May 24, 2011 3:43 pm

Re: using delphi for custom actions

Thanks for looking, ive allready looked through "most" of the internet e.g Google for such information, so had allready browsed at this.... but had some doubts as its pretty ancient...

was hoping for some way to use the com server and the interfaces msiexec exposes, but such information as of how that would work seems extremely hard to come by... especially for delphi.


/carl

Return to “Common Problems”