Hi,
I`m using PrimalScript Version 7.3.103 x64 in Windows 10 x64.
When I convert vbscript to executable, if I try to run that executable in windows server 2003, I get the error
"C:\windows\MyScriptTest.exe is not a valid Win32 application."
then I close the message window and in the command line console I see a message = "Access Denied".
I already tried to use 32 bit only instead of native, but I get the same error.
I ran this executable with Admin Permissions.
In the package settings I have The script engine option "SAPIEN Script Host (Command Line)" selected with Native Target.
Is this a .NET 4 issue? since Windows 2003 does not have .NET 4 how can I solve this? Can I download a older version of the Primal Script that allows this?
Not valid Windows Win32 application error
Forum rules
DO NOT POST LICENSE NUMBERS, ACTIVATION KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.
Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
DO NOT POST LICENSE NUMBERS, ACTIVATION KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.
Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
Not valid Windows Win32 application error
- Attachments
-
- 3.png (4.82 KiB) Viewed 7243 times
-
- 2.png (8.49 KiB) Viewed 7243 times
-
- 1.png (59.59 KiB) Viewed 7243 times
- Alexander Riedel
- Posts: 8488
- Last visit: Tue Apr 16, 2024 8:42 am
- Been upvoted: 37 times
Re: Not valid Windows Win32 application error
If you use the 'native' option, the starter executable is built against the .NET 4.5 framework. In order to use this mechanism you will need to install that.
If you package the VBScript with the 32 Bit option and the SAPIEN Script Host, there is no dependency on a .NET runtime. The executable uses the Visual Studio runtime.
Since Server 2003 is equivalent to Windows XP, this may no longer be supported.
But ultimately, it depends on your server configuration.
You executable file may be locked, your server may not allow running things form the root directory, your server may be configured to not run files that are not signed etc.
An older version of PrimalScript has ultimately less options and will not alleviate any issues on the machine.
I would suggest to build this for the native platforms you need it for and see that it works on these machines.
You can use this http://www.dependencywalker.com/ to see what your exeutable needs and what is not there.
Please note that this tool does not work for .NET assemblies in the same manner.
If you package the VBScript with the 32 Bit option and the SAPIEN Script Host, there is no dependency on a .NET runtime. The executable uses the Visual Studio runtime.
Since Server 2003 is equivalent to Windows XP, this may no longer be supported.
But ultimately, it depends on your server configuration.
You executable file may be locked, your server may not allow running things form the root directory, your server may be configured to not run files that are not signed etc.
An older version of PrimalScript has ultimately less options and will not alleviate any issues on the machine.
I would suggest to build this for the native platforms you need it for and see that it works on these machines.
You can use this http://www.dependencywalker.com/ to see what your exeutable needs and what is not there.
Please note that this tool does not work for .NET assemblies in the same manner.
Alexander Riedel
SAPIEN Technologies, Inc.
SAPIEN Technologies, Inc.
Re: Not valid Windows Win32 application error
Ok, I`ll check that , regarding to Native Mode, when I run the in systems that don`t have the correct .NET version, I get a Window Error warning to install the minimum .NET version. If I`m logged to the machine I can click the OK button of that Window Error, but if I use a remote session or a script that "calls" that executable, I end up with a remote command line waiting for someone to hit the OK button of that Windows message. Is it possible to redirect or ignore those Windows Errors when starting the executable?
- Alexander Riedel
- Posts: 8488
- Last visit: Tue Apr 16, 2024 8:42 am
- Been upvoted: 37 times
Re: Not valid Windows Win32 application error
No. Microsoft decided to make the system display a message box. Nothing you or I can do about that.
Alexander Riedel
SAPIEN Technologies, Inc.
SAPIEN Technologies, Inc.