Pass Session.Property("APPDIR") to Exe - 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!

ramit
Posts: 90
Joined: Thu Dec 18, 2008 11:51 am

Pass Session.Property("APPDIR") to Exe

Hi Cosmin,

I am creting an exe [in C#] which read a file (app.config) from Session.Property("APPDIR") location and update it.

My question is How I can pass Session.Property("APPDIR") to exe (which is included as Custom Action).

Thanks for help.

Thanks
Amit
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: Pass Session.Property("APPDIR") to Exe

Hi Amit,

Unfortunately EXE custom actions run in a different process, so they don't have direct access to installer properties. However, you can use the APPDIR property in the command line of the EXE custom action to pass the installation path to the EXE. Note that the EXE needs to be modified to receive a path as a command line parameter.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”