So I am trying to check if an update is available using the autoupdater in C#. Using the following command:
autoupdater.exe --mode unattended
And following the post (http://stackoverflow.com/questions/1469764/run-command-prompt-commands) to get a process that can execute cmd.exe in C#.
My issue is that when I install my application in Program Files (x86) and run this code it never finds an update. If I place it somewhere else (say User\Documents\) it can find the update.
Also running the autoupdate.exe in Program Files (x86) manually seems to find the update correctly, it only doesn't work when run through C# when in Program Files.
At first I thought it might be a UAC thing, but disabling UAC also does nothing. Does anyone have any suggestions why this might be happening? I have tried setting the following properties to the Process.StartInfo:
WindowStyle = ProcessWindowStyle.Hidden
FileName = "cmd.exe"
Verb = "runas"
UseShellExecute = true
Any help would be appreciated!
Please sign in to leave a comment.