FS-Keypad Forums
Running from FSUIPC - Printable Version

+- FS-Keypad Forums (https://fskeypad.rosscarlson.dev/forums)
+-- Forum: FS-Keypad (https://fskeypad.rosscarlson.dev/forums/forumdisplay.php?fid=1)
+--- Forum: Beta Testing (https://fskeypad.rosscarlson.dev/forums/forumdisplay.php?fid=3)
+--- Thread: Running from FSUIPC (/showthread.php?tid=10)



Running from FSUIPC - DakotaPilot - 07-18-2021

I use FSUIPC to start some programs I need running after P3D is started and decided to have it run the various FS KeyPad files.  I added the information copied from a shortcut to the fsuipc.ini RUN section.

Run2=READY,CLOSE,C:\Users\Brett\AppData\Local\FS-Keypad\FS-Keypad.exe "C:\Users\Brett\AppData\Local\FS-Keypad\Keypads\303df744-c367-4681-a409-4ac2f187b39e.json"

However, this failed to run with an error 267 from Windows.  I then wrote a Powershell script to do some testing and found that as long as I change to the FS-KeyPad directory (Local/FS-KeyPad) that command line will work.  However, if I ran the script from another directory it failed to run the FS-KeyPad.

It appears that despite the fact FS-KeyPad is given the entire path to the JSON file it only uses the filename and assumes it's in the Keypads directory so it can't find it unless you change to the FS-Keypads directory.  The shortcut works because the working directory is given so it effectively does the change to the directory.

I know this is a minor issue and I'm working around it by giving FSUIPC the powershell script to run it but it would be nice at some point to be able to add the command line as shown above to FSUIPC without having to create a script.


RE: Running from FSUIPC - rcarlson - 07-20-2021

Hi DakotaPilot,

The app will actually load the keypad definition file from any path, not just appdata\local\fs-keypad\keypads. You can test this by moving the file to some other location and updating the shortcut.

The "Start In" working directory in the shortcut is also irrelevant. You can test this by changing it to something other than the folder where the exe is located, and it will still work.

Do you have any details on the error other than just the number 267?


RE: Running from FSUIPC - DakotaPilot - 07-20-2021

That was the Windows error number and all I could get. Basically invalid directory (https://www.ibm.com/support/pages/return-code-267-when-trying-run-execprogram-1157-sterling-gentranserver-microsoft-windows). I do know that in my script if I don't cd to the FS KeyPad directory it fails, too.

I can try some more tests.


RE: Running from FSUIPC - DakotaPilot - 07-20-2021

Okay. More testing. From the command line when I'm in my home directory it works. Same with the Powershell script. I'll go back to the John Dowson of FSUIPC and let him know what I found. We were discussing it before I posted here so it must be something in the way FSUIPC process that command. Other commands run fine.


RE: Running from FSUIPC - rcarlson - 07-20-2021

Okay, thanks for reporting back with what you found.


RE: Running from FSUIPC - DakotaPilot - 07-21-2021

John Dowson said he'd look into it on his end.


RE: Running from FSUIPC - DakotaPilot - 07-22-2021

As a followup. John found an issue in FSUIPC that has been there for years on processing the command line. He gave me a fixed version.


RE: Running from FSUIPC - rcarlson - 07-22-2021

Great, thanks for reporting back with the fix.


RE: Running from FSUIPC - DakotaPilot - 07-23-2021

Your are welcome. I didn't want to leave it hanging.


RE: Running from FSUIPC - MrScott - 08-22-2021

(07-22-2021, 04:00 PM)DakotaPilot Wrote: As a followup. John found an issue in FSUIPC that has been there for years on processing the command line.  He gave me a fixed version.

The version of FSUIPC  I am running is the free one for use with MSFS2020. It starts each time MSFS is launched in order to connect my FSEconomy client. As far as I know it is the only thing it is running to support. Is the NEW version John sent you different? I have not updated it since my original install over a year ago.

Scott