Closed thegoodtgg closed 5 months ago
Although, I haven't found any apparent evidences from ms doc. I guess it's related to the way call "CreateProcess" to create PyStand process.
I only found this from LoadLibrary - Remarks
The first directory searched is the directory containing the image file used to create the calling process (for more information, see the CreateProcess function). Doing this allows private dynamic-link library (DLL) files associated with a process to be found without adding the process's installed directory to the PATH environment variable.
However in our situation, python3.dll is loaded from working directory not the application directory.
thanks, but PyStand is using tabs for indentation, while you are using spaces, please keep consistency.
According the doc about "LoadLibrary" and "SetDllDirectory", when PyStand not run as sub-process, dll search path not including "runtime" directory, PyStand failed to load python3.dll. Using SetDllDirectory instead of "SetCurrentDirectory" would fix the problem.