Jump to content
Sign in to follow this  
am632

Windows installer service wont start when running setup via script

Recommended Posts

am632

Hi,

I have a script which is the following...

Func _Begin_Install()
    GUICtrlSetState($Button_Install, $GUI_DISABLE)
    RunWait(@ScriptDir & "\setup.exe")
    GUICtrlSetState($Button_Install, $GUI_ENABLE)
EndFunc

Basically the setup will start to run but then I get the error message "The windows installer service could not be accessed"

The setup works if I run it manually (not through my script)

Also I have tried adding #RequireAdmin to the top of my script with no difference.

Any Ideas?

Thanks

Share this post


Link to post
Share on other sites
JLogan3o13

Hi, am632. You mention that it works manually, but not what "manually" entails. Can you tell us what happens when you run it from:

  • Double-clicking Setup.exe
  • Typing <path>Setup.exe into the Run line
  • Typing <path?Setup.exe into a command line window

√-1 2^3 ∑ π, and it was delicious!

How to get your question answered on this forum!

Share this post


Link to post
Share on other sites
am632

Hi,

Thanks for the replies, I have no internet at home at the moment which is why I didnt reply right away.

Firstly, by manually I mean if I double click the setup.exe in windows explorer the setup installs the program witholut any problems.

I also tried your suggestion (Morthawt) and used 'ShellExecuteWait' instead but still got the same problem.

Thanks for the replies

Share this post


Link to post
Share on other sites
am632

Hi,

I tried running from cmd and from the run box, and both installed the setup without error.

Thanks

Share this post


Link to post
Share on other sites
Danny35d

Try to add the working directory to RunWait function.

RunWait(@ScriptDir & "setup.exe", @ScriptDir)

or

RunWait(@ScriptDir & "setup.exe, @WorkingDir)

 


AutoIt Scripts:NetPrinter - Network Printer UtilityRobocopyGUI - GUI interface for M$ robocopy command line

Share this post


Link to post
Share on other sites
am632

Thanks for the suggestion, I'll try that this afternoon and post back result

Thanks

Share this post


Link to post
Share on other sites
am632

Hi, I tried all what you have said but still getting the problem. I dont know what to try next as this has never happend before. Any more ideas?

Thanks for the help

Share this post


Link to post
Share on other sites
am632

Hi,

I realised it works ok on windows XP but not 7, I fixed it though. I simply uninstalled autoit and reinstalled from the website and now it works, maby there is a bug in the version I was using (was the same version on both my machines)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×