"Deferred with no impersonation" Greyed out - 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!

AM0nty
Posts: 3
Joined: Fri Sep 08, 2006 5:27 pm

"Deferred with no impersonation" Greyed out

Hi

I am using Version 4.8.1, although my project was intially created in Version 4.4.x

I am trying to run my installer on Windows Vista, and the first Custom Action I run is a vbs script that registers an ActiveX DLL. This fails, so reading through the forum I see that I have to set "Deferred with no impersonation" to get it to work, but it is greyed out.

The custom action is in the UI Custom Actions section.

What do I have to set this "Execution Option"?

Thanks in advance

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

Hi,

Please note that a "Deferred" custom action can be scheduled only between the InstallInitialize and InstallFinalize sequences (which are present only under "InstallExecuteSequence").

You can read more about this here:
http://msdn2.microsoft.com/en-us/library/aa368268.aspx

You can register an ActiveX DLL by using the "Auto Register" feature like this:
- in the "Files and Folders" page you right-click the DLL and select "Properties"
- in the "Edit File" dialog you select the "Auto Register File (DLL, OCX, etc.)" option
- in the "Registration Method" combo box you select "Extract registration info"

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
AM0nty
Posts: 3
Joined: Fri Sep 08, 2006 5:27 pm

Hi

Thanks for the response, I now understand why I don't have the option.

The registering of the DLL is for a tempory file, which does not have a "Auto Register File" option. The reason I am doing this, is to get a file selection dialog box. Looking through the forum, this is now built into AI, but not in v4.8.1. The proposed solution is to write a DLL with the dialog in it.

Now as I already had an ActiveX component registered and available for the UI sequence I decided to use that. But this does not work as I cannot register the ActiveX under Vista.

So I suppose the real question is how do I get a File Selection dialog box under Windows Vista? If it is a DLL (not ActiveX) how do I call it from AI and return the file name to a property.

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

Hi,
But this does not work as I cannot register the ActiveX under Vista.
Please make sure that the DLL you are using can be registered on Windows Vista (you can use regsvr32.exe in the command line). Note that even if the registration succeeds, you can register the DLL only in the "InstallExecuteSequence" using a "Deferred with no impersonation" "Exe with working Dir" custom action (in the "InstallUISequence" the registration will fail).
So I suppose the real question is how do I get a File Selection dialog box under Windows Vista? If it is a DLL (not ActiveX) how do I call it from AI and return the file name to a property.
I recommend that you upgrade to a version higher than 5.0 (Enterprise license) and use our tutorial in order to accomplish what you need:
http://www.advancedinstaller.com/user-g ... -file.html

If you cannot upgrade then you can create your DLL own custom action that will use the GetOpenFilename function:
http://msdn2.microsoft.com/en-us/library/ms646927.aspx

You can read more about DLL custom actions here:
http://msdn2.microsoft.com/en-us/library/aa368338.aspx

Also, we have an example for a DLL custom action, please take a look:
http://www.advancedinstaller.com/user-g ... n-dll.html

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

Return to “Common Problems”