LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Open file vi return <not a refnum> in executable

Solved!
Go to solution

Hey there,

 

I have a the "Open/Create/Replace File" vi in an executable. It works perfectly fine on my development machine, both in development and in the executable. When I install it on another machine, the <not a refnum>-function returns true.

It seems to me, that the file is not opened properly, even though it exists. There is no error, indicating that there has been a problem opening the file, so I am confused.

 

Did any of you come across this ... bug(?) and knows what to to about it?

 

Thanks in advance

 

This is the concerned code

0 Kudos
Message 1 of 6
(2,980 Views)

Hi,

 

On your developement PC you have complete LabVIEW package so its working fine but on other PC you don't have LabVIEW only you are installing the installer. So my suggestion that you can check your installer builder that you are building your installer correctly or not and also check you have include all required additional installers in your installer.

Thanks and Regards
Himanshu Goyal | LabVIEW Engineer- Power System Automation
Values that steer us ahead: Passion | Innovation | Ambition | Diligence | Teamwork
It Only gets BETTER!!!
0 Kudos
Message 2 of 6
(2,974 Views)

Hi Soana,

 

two notes:

- "There is no error": well, you don't use the error cluster at all. USE IT! SHOW IT! ANALYZE IT!

- Did you check the path used in the executable? Is the path correct?

 

Conclusion:

Use error cluster, show a dialog with error number and path in case of an error for debugging purposes!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 3 of 6
(2,962 Views)

Would I need any other additional installers for processing files than thte runtime of the LabVIEW version I am using?

0 Kudos
Message 4 of 6
(2,960 Views)
Solution
Accepted by Soana-Phikeste

Now I feel very stupid.

There actually is an error - the file was not found. Smiley Embarassed

 

I just thought that this error message (file not found) would show automatically if I did nothing to suppress error messages, like wiring an error cluster.

 

 

0 Kudos
Message 5 of 6
(2,948 Views)

Hi Soana,

 

to show the error messages is just the default setting of the development environment...

 

It's nice to see "I'm feeling stupid" marked as solution 😄

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 6 of 6
(2,941 Views)