Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Vista Newsgroups > Vista General

Vista - SetupIterateCabinet failing from Custom Action .dll

Reply
 
Old 10-26-2006   #1 (permalink)
microbert


 
 

SetupIterateCabinet failing from Custom Action .dll

I use Visual Studio 2005 to deploy my application.

I have a Custom Action .dll that's called during the Install phase. (The
entry point is the standard Install( MSIHANDLE ).)

I'm installing a .CAB file and am calling SetupIterateCabinet() from this
Custom Action .dll and it is returning ERROR_ACCESS_DENIED.

Appears as though Custom Action .dll's are not run with the UAC elevated
privileges of the .msi file.

I tried adding a .manifest to give the .dll elevated privileges, but then
Windows XP barks that there is an unrecognized token. I need this .msi file
to run under both Windows XP, Windows 2000, and Windows Vista.

Because this is a Custom Action .dll there is no way I can wrap the function
in a COM object and call it with the CoCreateInstanceAsAdmin() (or whatever
it is called).

Is there some other method I can use to insure that the Custom Action runs
with the appropiate privileges so that the SetupIterateCabinet() call will
succeed?

Thanks!

-Mike.

My System SpecsSystem Spec
Old 10-27-2006   #2 (permalink)
DMB


 
 

Re: SetupIterateCabinet failing from Custom Action .dll

Wrong newsgroup. You need to consult your MSDN.

"microbert" <microbert@discussions.microsoft.com> wrote in message
news:66DB7FE5-5D4B-4C9B-B3EB-DB7B77236191@microsoft.com...
>I use Visual Studio 2005 to deploy my application.
>
> I have a Custom Action .dll that's called during the Install phase. (The
> entry point is the standard Install( MSIHANDLE ).)
>
> I'm installing a .CAB file and am calling SetupIterateCabinet() from this
> Custom Action .dll and it is returning ERROR_ACCESS_DENIED.
>
> Appears as though Custom Action .dll's are not run with the UAC elevated
> privileges of the .msi file.
>
> I tried adding a .manifest to give the .dll elevated privileges, but then
> Windows XP barks that there is an unrecognized token. I need this .msi
> file
> to run under both Windows XP, Windows 2000, and Windows Vista.
>
> Because this is a Custom Action .dll there is no way I can wrap the
> function
> in a COM object and call it with the CoCreateInstanceAsAdmin() (or
> whatever
> it is called).
>
> Is there some other method I can use to insure that the Custom Action runs
> with the appropiate privileges so that the SetupIterateCabinet() call will
> succeed?
>
> Thanks!
>
> -Mike.


My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
Setup project Custom Action fails under Vista .NET General
!Error 2738. Could not access VZScript run time for custom action Software
winrm invoke a custom action PowerShell
Custom Keyboard action? Vista General
MSI Custom Action DLL does not have administrator rights Vista General


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46