LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Python Node with file path as input parameter

Solved!
Go to solution

Hi All,

I'm not able to use a Python node that use a path as input.

I also try to use a string and then convert it to a path inside the python code but in any case I always have an error message that file path does not exist.

I'm using LabVIEW 2019 and if I run the python code with PyCharm It works with the same file at the same path.

 

Regards

Golzio

0 Kudos
Message 1 of 3
(2,863 Views)

@golzioge wrote:

Hi All,

I'm not able to use a Python node that use a path as input.

I also try to use a string and then convert it to a path inside the python code but in any case I always have an error message that file path does not exist.

I'm using LabVIEW 2019 and if I run the python code with PyCharm It works with the same file at the same path.

 

Regards

Golzio


Which Python.exe are you using in PyCharm?

0 Kudos
Message 2 of 3
(2,832 Views)
Solution
Accepted by golzioge

Hi,

thank you for your time.

I'm using Python 3.6.4 64 bit version and also LabVIEW is 64 bit.

I solved my issue simply passing the path as a string replacing \ with / (I already did this before asking here).

The key point was not using quotation mark for path when calling the code from Python node.

Just to be clear:

 

a= pd.read_csv('File_Path')   ERROR

 

a= pd.read_csv(File_Path)    OK

 

All the best

Golzio

 

 

0 Kudos
Message 3 of 3
(2,816 Views)