Cannot create process, error code: 193

Hi,

I have followed https://developer.garmin.com/connect-iq/connect-iq-basics/getting-started/ and then https://developer.garmin.com/connect-iq/connect-iq-basics/your-first-app/ but I am stuck at Running the Program, when I try run it I get *  The terminal process failed to launch: A native exception occurred during launch (Cannot create process, error code: 193). 

I have tried manually running the command in CMD as administrator but I get the error Access is denied and a popup that says "This app can't run on your PC, check with the software publisher"

This is on windows 10 using VS code with the 6.4.1 Connect IQ SDK.

Any help is appreciated thanks.

  • I fixed this by reinstalling java. but now I run the command command in CMD (because I had to manually edit the heap size) it goes to BUILD SUCESSFUL but the simulator does not open.

  • I found that running the build manually through CMD does not open the simulator even if the build is successful, the simulator only opens when it is run from within VS code using the run or run without debugging. This is a problem for me because I have no way of editing the heap size from the command that runs automatically unless I manually edit it a re-run it in a separate terminal which as mentioned above does not open the simulator.

    I tested and it all works fine on my laptop but not on my desktop which is where im getting the Error occurred during initialization of VM
    Initial heap size set to a larger value than the maximum heap size

    when running the app.

    C:\Program Files (x86)\Common Files\Oracle\Java\javapath\java.exe '-Xms1g', '-Dfile.encoding=UTF-8', '-Dapple.awt.UIElement=true', '-jar', 'c:\Users\broom\AppData\Roaming\Garmin\ConnectIQ\Sdks\connectiq-sdk-win-6.4.1-2023-12-04-6cafd260d\bin\monkeybrains.jar', '-o', 'bin\app3.prg', '-f', 'c:\Users\broom\OneDrive\Documents\Projects\SMARTWATCH\Garmin\app3\app3\monkey.jungle', '-y', 'c:\Users\broom\OneDrive\Documents\Projects\SMARTWATCH\Garmin\keys\app1key\developer_key', '-d', 'fenix7pro_sim', '-w'