The output of the WriteMessage() is: ['.','D:\Sources\VC2022\GSM_sim\xlw\x64_Release']
As the script will be used on multiple PC's it is not convenient to change the path to my managed dll each time.
Therefore I would prefer if I could add this path to an environment variable (Windows 10).
I read somewhere that the variable 'PYTHONPATH' should do it.
But it does not make a difference, unfortunately.
Can anyone help?
Thanks and greetings,
Auke Nauta
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thanks for your help.
Unfortunately, in general, the DWSIM projects will be 'passed around' from user to user.
As such, they will not reside at the same location as the DLLs.
I would like to avoid every user to have to modify the scripts every time.
I will look into it some more...
Greetings, Auke
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I have a CustomUO IronPython script which I use a lot.
It -partly- contains this code:
The output of the WriteMessage() is:
['.','D:\Sources\VC2022\GSM_sim\xlw\x64_Release']
As the script will be used on multiple PC's it is not convenient to change the path to my managed dll each time.
Therefore I would prefer if I could add this path to an environment variable (Windows 10).
I read somewhere that the variable 'PYTHONPATH' should do it.
But it does not make a difference, unfortunately.
Can anyone help?
Thanks and greetings,
Auke Nauta
You can try
This assumes that your DLL is in the same directory as the sim file.
Hi Daniel,
Thanks for your help.
Unfortunately, in general, the DWSIM projects will be 'passed around' from user to user.
As such, they will not reside at the same location as the DLLs.
I would like to avoid every user to have to modify the scripts every time.
I will look into it some more...
Greetings, Auke
I understand. But will you be able to know where your DLL will reside in the other computers?
Well, not really.
Therefore an environment variable would be ideal.
This would need to be set just once in order for any project to be functional.
Usually you can get the paths for DLLs from registry or from env vars:
Hi Daniel,
This works exactly as I intended.
Thanks!!!
Greetings,
Auke