Why Do I Get an Error in CVI When Calling viMoveIn or viMoveOut VISA Functions? Primary Software: Driver Software>>NI-VISAPrimary Software Version: 4.1 Primary Software Fixed Version: 4.3 Secondary Software: LabWindows/CVI Development Systems>>Full Development System
Problem: Why do I get a user protection error in LabWindows/CVI when calling the viMoveIn or viMoveOut NI-VISA functions? Solution: This is a known issue in NI-VISA versions 4.1 and 4.2, that can be seen when using CVI in Debug mode. CVI is incorrectly expecting a larger buffer than is actually necessary. As long as a sufficiently large buffer is passed for the number of items specified, then it is safe to disable the false user protection warnings by doing one of the following: 1) Call SetBreakOnProtectionErrors(0); before each call to one of the affected functions and SetBreakOnProtectionErrors(1); after each call. 2) Add the following pragmas to any source file that calls one of the affected functions or to a header file included in any source file that calls one of the affected functions: #pragma DisableFunctionRuntimeChecking viMoveIn16The issue will be fixed in NI-VISA versions 4.3 and later, and did not exist in versions 4.0 and earlier. The Bug ID is 4E3DCFAB. Related Links:
Attachments:
Report Date: 10/11/2007 Last Updated: 02/11/2008 Document ID: 4EAET3QA |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
