Administrative Setup via Command Line - 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!

Hale
Posts: 4
Joined: Thu Oct 11, 2012 11:54 am

Administrative Setup via Command Line

Hello,

i'm trying to start my setup.exe in administrative mode via cmd using the command line: "setup.exe -a". It didn't work, so i tried to start it with the command line: "setup.exe -a //".
I searched for a solution of this problem but the result was frustrating.
So i got an idea:
I wanted to get the command line property and edit it in a vbscript but the problem ist that i haven't found the correct property by now.

So my questions are:
1.)
Is it possible to build a setup and run it in administrativ mode using command line "setup.exe -a" and how can I put it, if so?
2.)
Is it the a property which contains the command line and in which sequence do i have to add the vbscript to edit it?

I'm using Advanced Installer 8.9

I hope you can help me.

Regards,
Michael
Daniel
Posts: 8283
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Administrative Setup via Command Line

Hello Michael,

In order to run your EXE installer in administrative mode you can use a command line like this:

Code: Select all

setup.exe /a //
Let us know if this helps, otherwise give us more details about your scenario.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Hale
Posts: 4
Joined: Thu Oct 11, 2012 11:54 am

Re: Administrative Setup via Command Line

Hello Daniel,

thanks for your response but this still doesn't work. I always get an error message like "The syntax for the file name, directory name or volume label syntax is incorrect."

Well my extract path is: "[AppDataFolder][|Manufacturer]\[|ProductName]\install" and I'm starting the Setup.exe on my desktop.
[EDIT] I also tried to clear the extract path but still the same error message.
If i try this command line >>"C:\Users\AdminUser\Desktop\Setup.exe" /a "C:\Users\AdminUser\AppData\Roaming\MyCompany\MyProduct\install\Setup.msi"<< it works correctly. Unfortunately isn't this the commad line that my Admin wants to see.

The task was to create a setup.exe where you can start the administrative setup via "setup.exe -a". I realized that this is impossible so i hope u can help me to fix it that I can use "/a //" correctly.

Greets,
Michael
Daniel
Posts: 8283
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Administrative Setup via Command Line

Hello Michael,

You could encounter this behavior if you are using our "Enhanced User Interface" feature because packages created with Enahnced UI does not support the administrative command line. So, as a workaround you can disable the Enahnced UI from "Themes -> Settings" tab or you can proceed like this:
1. Extract the MSI from your EXE package using a command line like this:

Code: Select all

setup.exe /extract <path>
2. Use an administrative mode command line, on the extracted MSI, like this:

Code: Select all

msiexec.exe /a setup.msi
All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”