LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

CVI 9.0 ambiguous error - "A custom control callback has raised an exception"

Thsi has been causing CVI to crash or lock up.

 

I have gotten this error a few times recently on a project.  It usually comes up when I add or make changes to a procedure involving PlotXY or graph controls.  The work around has been to not use any global variables with the  function being added when the error occurs.  I am not using any custom controls.  I looked at the posts that result when searching for this problem; is there any new information regarding this error?

 

Thanks - Dave

0 Kudos
Message 1 of 20
(5,543 Views)

Hey Dave,

 

Does this happen when you are broken in the debugger and are attempting to hover over a variable to see the value of the variable in a tooltip?  If not, what are the exact circumstances under which you see this error?  Is this something you can reliably reproduce, or is it a seemingly random occurance?

 

Thanks!

 

NickB

National Instruments 

0 Kudos
Message 2 of 20
(5,532 Views)

NickB,

 

It happens during the build.  After the source files compile but before the executible module is created.  I have been running in debug mode.  The most recent time it occurred was when I declared a double Array[110] globally that is used in a PlotXY procedure.  It always occurs at the same time if it is going to happen.  Putting the declaration inside the procedure has been a work around but I need the double Array at another place in the program and declaring and using it inside multiple procedures seems like bad form so I have been trying to get it to work as a globally declared arrray.

 

Thanks,

Dave

0 Kudos
Message 3 of 20
(5,529 Views)

Hi Dave,

 

The best way for us to reproduce this issue would be if we could get the code you are using.  If possible, could you post your code to our internal ftp site?  This ftp site is publicly write-only, so only NI employees will be able to read the code.  The site is ftp://ftp.ni.com/incoming .  Open up a Windows Explorer window and paste the address into the address bar, then copy the code into the folder.

Eric B.
National Instruments
0 Kudos
Message 4 of 20
(5,496 Views)

Hi Eric,

 

I have since found a work around to the problem and it no longer shows up.  I would modify global variables, especially arrays and the error would disappear.  The last time I saw it was before I removed a declaration for 2 arrays of double of 1000 elements.  The arrays were not being used anywhere in the program.  The functions that used them had been eliminated but I forgot to remove the arrays.  Bad form I know,  but I wouldn't think this should cause this error.  I don't know if this change actually caused any error or fixed anything but the problem went away.  I had some saved version of the folders but they now compile and link okay without error.  ??!!

 

Will the link for the ftp site you provided be available for a while if the problem returns?

 

Thanks,

Dave

0 Kudos
Message 5 of 20
(5,482 Views)

NickB,

 

We have been experiencing the same problem as you describe. ...broken in the debugger and are attempting to hover over a variable to see the value of the variable in a tooltip...

 

Is there a fix for this problem?

 

Rodney

0 Kudos
Message 6 of 20
(5,472 Views)

Eric B.

The error has showed up again.  I copied the source and project files into a zipped file named 12S AF Software.zip and downloaded into the incoming folder of your ftp site.

Thanks,

Dave

0 Kudos
Message 7 of 20
(5,467 Views)

Hello Rodney,

 

We were able to track down the cause of the issue you describe (hovering over a variable causing the exception).  There will be a fix for this in the upcoming maintenance release of CVI.  In the meantime, this problem is related to the new pre-compiled header feature - so there are a couple things you can do:

 

 

  • turn off pre-compiled headers 
  • delete the cvibuild directory and mark your project for recompilation when you experience this exception
 
NickB
National Instruments  

 

0 Kudos
Message 8 of 20
(5,462 Views)

Dave,

 

Thanks for sending your code.  I am trying to compile it, but I am missing two header files: flexmotn.h and MotnCnst.h .  Could you attach those to a forum post or put them on the ftp site as well?

Eric B.
National Instruments
0 Kudos
Message 9 of 20
(5,436 Views)

Eric B,

I put the files on NI's ftp site. They are in a file named 12 AF Include files.zip.

Thanks,

Dave

0 Kudos
Message 10 of 20
(5,429 Views)