03-22-2022 12:19 PM
I get Error 1761 when I try to open a python session in LabVIEW, before any .py file is opened.
I am using LV 2021, Python 3.9.7.
I have a straightforward python install, not using anaconda or anything.
I have read the other topic on this error and believe I have set-set up my system environment variables.
My python install is at C:\Apps\Python39 and so I have entered this as C:\Apps\Python39\ in the system environment variables under "Path".
I have rebooted and the error remains.
Have I made any mistakes?
FYI error 1761 occurs at probe 1
snip of path environment variables.
tks and regards.
Solved! Go to Solution.
03-29-2022 04:56 AM
In case anyone else gets this issue the initial reason was that when I checked via cmd line, my default python version was 3.9.7 64bit but my LabVIEW is 2021 32bit.
I tried pointing the LabVIEW Open Python Session vi to an older 3.8.x 32bit python install but still got Error 1761.
I installed python 3.10.x 32bit but the cmd line default python version was still 3.9.7 64bit.
I uninstalled all python versions and started again with 3.10.x 32bit, then added python 3.9.x 64bit which I needed for a legacy tool.
PC now sees 3.10.x 32bit as the default and now LabVIEW python integration works.
I thought the "Python version" terminal on "Open Python Version.vi" would deal with selecting the version of python to use, maybe it does and my installs were just screwed up I guess.
03-30-2022 12:31 PM
I ran into a similar issue. I believe it may have to do with the order in which the Python versions appear in the PATH variable. The system will use the first one it comes to as it tries to resolve the paths to the executable. Uninstalling and reinstalling probably reordered your Python versions in PATH resulting in the "correct" version being the default (appearing first in the list).
@MrSpanman wrote:
I thought the "Python version" terminal on "Open Python Version.vi" would deal with selecting the version of python to use, maybe it does and my installs were just screwed up I guess.
I agree that LabVIEW should do a better job of choosing the version based on the version string you provide. Otherwise, why would you need to provide it?
03-22-2023 07:03 AM
I had the same problem. I found that there were two files in the wrong way.
The two files "niPythonInterface.dll" and "niPythonHost.exe" in the NIPythonInterface folder need to be copied to the labview installation directory (D:Program Files (x86)National InstrumentsLabVIEW 2021)
10-23-2024 12:27 AM
and you, my friend, is the real hero