Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

All plots & cursors disappeared from Scattergraph

All plots, axes, and cursors have disappeared from my Scattergraph control, and all legends from legend control.  This is a large app under development for 1 year, no problem up to now.  When I try to view the form containing the control in the Visual Studio (VB.NET) development environment, I get a long string of build error messages including "Member not found", "Object reference not set to an instance of the object", "Object type cannot be converted to target type", and "Variable X was either undeclared or never assigned".  However, the code at the top of the form seems to have all the proper declarations and initializations, and matches same code in earlier versions.   Bringing back source from slightly earlier version does not fix problem.   Nevertheless, the app builds and runs, showing graph, plots, cursors OK.  Why doesn't it display properly in the development environment?
0 Kudos
Message 1 of 3
(2,973 Views)

Go the References node for the project in the Solution Explorer, right-click on NationalInstruments.Common.dll, NationalInstruments.UI.dll, and NationalInstruments.UI.WindowsForms.dll and click Properties, then check the Copy Local setting in the Properties window.  Is this setting true for any of these assemblies?  If so, that could be the cause of the problem.  The copy local setting must be false for each of those assemblies.  If it is set to true, the Windows Forms designer will load the assemblies multiple times (once from the local copy and once from the GAC), hence causing type conflicts that will result in the errors that you are seeing.  Note that this is a general issue with the Windows Forms designer and has nothing to do with Measurement Studio assemblies.  For example, try changing the copy local setting for the System.Windows.Forms.dll assembly to true, close the designer, and re-open the designer.

If that is not the problem, have you upgraded to a newer version of Measurement Studio?  This could possibly happen if you have mismatched dependency versions.  Also, have you tried diffing the code between a time that it worked and now?  If so, what are the differences?  Have you tried diffing the project file and checking for differences?  If so, what are those differences?

- Elton

Message 2 of 3
(2,969 Views)
You got it!  Fixed the problem immediately.  Thanks!
0 Kudos
Message 3 of 3
(2,965 Views)