LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Runtime error in CVI 6.0 (IDE and RTE)

I am recompiling old code in CVI 6.0 and expect to make some changes, but I now get the following runtime errors:

Library Function error - returns -1. This is for GetFileSize which is supposed to return -1 when a file is not found. My code handles this, but every time the function is called this error is generated. This along with several other runtime errors show up even though the code works when I hit continue. I am getting an error code back and handling the errors, but still the rt error message is generated as soon as the function returns -1. Can I just suppress these errors?

ALSO, I installed CVI 6.0 on my machine, then had to reinstall the CVI SQL toolkit. The toolkit supposedly has the same RTE as the IDE, but I want
to make sure. If not, would the toolkit install of the RTE have overwritten the IDE installed RTE if the IDE installed RTE was more recent?

Thank you,

Judy Harrigan
0 Kudos
Message 1 of 3
(2,977 Views)
You can go to project window and select option>>run options and deselect break on library errors (not the best idea). Option two is to use "SetBreakOnLibraryErrors".

example:

SetBreakOnLibraryErrors(0); // disables error message
GetFileSize(filename, &size);
SetBreakOnLibraryErrors(1); // enables error message

Hope that helps,
Steve
0 Kudos
Message 2 of 3
(2,977 Views)
Hello

I would think that the RTE should not be over-ridden. You can check the current version verison of the RTE that you have installed by using the Measurement and Automation explorer and going thru the software tree.
Or you can search for cvirte.dll and cvirt.dll and check its version

I hope this helps

Bilal Durrani
NI
Bilal Durrani
NI
0 Kudos
Message 3 of 3
(2,977 Views)