Path cannot be the empty string or all whitespace

Hello, I'm trying to install updates using command line args (C:\\Program Files\\Kryon Updater\\Configuration\\UpdateChecks\\wyUpdate.exe /fromservice -cdata=\"robot-client.wyc\" -server=\"http://myserver.com/Robot\\server-robot.wys\" -basedir=\"C:\\Program Files\\Robot\\19.5.0.58\" -updatepath=\"http://myserver.com/AutoUpdate/Robot\" -logfile=\"C:\\Program Files\\Updater\\Configuration\\UpdateChecks\\log.txt\)and i'm having this ecxeption: The update failed to install. - Path cannot be the empty string or all whitespace.I have no idea what is wrong, it worked earlier but now its crap)

Yurii wrote:> Hello, I'm trying to install updates using command line args (C:\\Program> Files\\Kryon Updater\\Configuration\\UpdateChecks\\wyUpdate.exe> /fromservice -cdata=\"robot-client.wyc\"> -server=\"http://myserver.com/Robot\\server-robot.wys\"> -basedir=\"C:\\Program Files\\Robot\\19.5.0.58\"> -updatepath=\"http://myserver.com/AutoUpdate/Robot\"> -logfile=\"C:\\Program> Files\\Updater\\Configuration\\UpdateChecks\\log.txt\)> and i'm having this ecxeption: The update failed to install. - Path cannot> be the empty string or all whitespace.> I have no idea what is wrong, it worked earlier but now its crap)

P.S. I.m usinf nssm.exe to run my app as service. It works ok without nssm, but with it it gives me an error

If you're using /fromservice, then you must actually be calling it from a service. Not from a regular app. Not from a scheduled app. Not from the commandline. Not from an emulated service.

From a real service.

Regarding commandline args not being passed. Hard to know. Likely NSSM mangling things. But don't use that. Create a real service.

Google "service in [your programming language]" and you'll find a thousand examples of a basic Windows Service shell that you can create.

We use dotnetcore console app that executes wyupdate.exe using ProcessStartInfo. When running the console app off windows service manager all is working well with /fromservice - wyupdate shows the update window and finishes after few seconds- but when we run it via service manager it fails - i guess it something to do with service desktop interaction- but we had tested it also and wyupdate window did not appear and the update did not succeed.

This is a real service - So googling will not help.

We already bought 10 licenses of wybuild but it fails to deliver.

Please provide a working c# based example using wyupdate /fromservice that runs from a windows service on windows server 2016 / 2019

We are releasing our product soon and have to get it to work ASAP

Thanks

Eyal

Use the log to record what is failing. Use the return codes. And before you start calling things from a service (a real one, not an emulated one), run things through using the UI first.

Never use /fromservice from console or from a GUI app. Only use it from a service running at the system level (not local user level). See the documentation. This is covered extensively.

With partial reports we cant actually help you. We need a lot of information.

running the wyupdate command manually all is working file with all the parameters. when removing the /fromservice - the whole process becomes manual - we are looking for a silent automatic installation and /fromservice (even from regular process) is doing a great work. the log we get is failure : "Path cannot be the empty string or all whitespace"

if there is a parameter other than /fromservice that does the update automatically please state it - but in any case under windows service it does not run and it is suspected that it tries to output a window but it cannot while working on windows service

we had converted the nssm to regular windows service - still same issuehere is the log file : 1/5/2020 13:18:21:835 PM: The update failed to install. - Path cannot be the empty string or all whitespace.1/5/2020 13:19:30:146 PM: The update failed to install. - Path cannot be the empty string or all whitespace.

as suspected - it has nothing to do with nssm - please help

we had managed to get it to work when supplying a user to the service than runs the wyupdate.exe but that is not a solution we can deliver as we do not have user/password on our clients machines - we need local system to be able to run the update successfully.

after rebuilding wyupdate.exe and adding some more useful logs we had managed to find the issue. we had used cudesktop and custartmenu for setting shortcuts. the issue is that while running with localsystem service - there is no current user desktop or start menu and the path returned are empty.

this fails the update. we are moving to : commstartmenu and commdesktop and had seen that it works well.

i think that wyupdate.exe should log better meaningful data such as the step it fails on or shortcut or file. also i think wyupdate.exe should continue to work and not stop after facing such issue.