Measurement Studio for VC++

cancel
Showing results for 
Search instead for 
Did you mean: 

how do i setup visual c++ 2008 to use measurement studio tools and NI-9401 digital inputs?

I am able to get Measurement Studio components to appear in the toolbox, but they are grayed out.
Can help be integrated into C++ 2008?
I am starting from scratch.
0 Kudos
Message 1 of 25
(11,673 Views)
Hi edp3,

- Are you trying to use unmanaged C++ (MFC) or C++/CLI in Visual Studio 2008?
- What items did you try and add to the toolbox (i.e was it .NET components or COM components)?
- Which items are greyed out?

I did want to mention that Measurement Studio doesn't currently support Visual Studio 2008.  This means that there is no integration into VS 2008 (i.e. no menus, no controls in the toolbox on install, etc).  However, you can use existing versions of Measurement Studio with VS 2008 as described in the Using Measurement Studio 8.1.2 and Prior in Visual Studio 2008 tutorial. 

Best Regards,
Jonathan N.
National Instruments
0 Kudos
Message 2 of 25
(11,660 Views)
I am trying to use MFC in 2008.
I added .NET components, all of them.
All are grayed out.
 
I followed the instructions in the link.  VB works but C++ does not.  I don't know how much more work is needed to get the development software into usable shape.  Another problem is none of the C++ help for Measurement Studio is installed because without Visual 2005 installed no NI help for C++ gets installed.
 
I am fairly up to speed with MFC.  I haven't used Visual Basic before, and it ain't the Basica that I once use to know and love.
0 Kudos
Message 3 of 25
(11,658 Views)

It has been suggested that I use Visual Studio 2005.

0 Kudos
Message 4 of 25
(11,658 Views)
Hi edp3,

If you have created a MFC application, then you would be using the ActiveX controls like CWGraph which are added to the toolbox via adding COM components. You don't use the .NET components in MFC but rather you use the .NET components in .NET languages like C#, VB.NET, or C++/CLI.

If you were using VS 2005 and MFC, you would see the ActiveX controls by default in the Toolbox, but again you won't have the .NET components because its not a .NET compliant language.

If you were using VS 2005, all the help for both C++ and .NET would be integrated into the VS 2005 help.

You can install the VS 2005 help on a machine with just 2008 which is discussed in the
Using Measurement Studio 8.1.2 with Microsoft Visual Studio 2008 KB. 

Hope this helps!

Best Regards,
Jonathan N.
National Instruments
0 Kudos
Message 5 of 25
(11,654 Views)

Well that was progress. I got a CWGraph to appear in the toolbox and I dragged one into a dialog box.  I says it is an evaluation copy, I have 30 days to buy it.  I bought Measurement Studio for Visual Studio .NET.  Do I need to register something, or did I buy the wrong thing?

Thanks

0 Kudos
Message 6 of 25
(11,650 Views)
Also, how do I read the input states of the NI-9401? Something gets instantiated right?
0 Kudos
Message 7 of 25
(11,648 Views)
Hi edp3,

With regards to your evaluation message, that would only occur if at one point you did have some evaluation copy of Measurement Studio and forgot to uninstall it. Then maybe you just installed the .NET components and not the C++ part. 

In the installer dialog of Measurement Studio, you can choose to install C++ support and .NET support. Since you are programming in MFC, you should have selected the C++ part. I would do a repair on the installer and look at the installer dialog and ensure that you have selected th C++ features.

With regards to your data aquisition question, you should probably ask that on the Digital I/O or Multifunction DAQ forums since this is a DAQ related question (i.e. since you use DAQmx to program that device I believe).

Best Regards,
Jonathan N.
National Instruments
0 Kudos
Message 8 of 25
(11,646 Views)
Hi edp3,

I reviewed my last post and wanted to clarify a few concepts. But first, I wanted to ask if you have already moved to VS 2008 or are you trying to decide whether its best to use VS 200 5 or 2008?

As I mentioned earlier, when you are developing in MFC with Measurement Studio, you are actually using the ActiveX controls (CWGraph, CWKnob, etc) to create your GUI.  When you use ActiveX controls in Visual C++, Visual C++ auto-generates MFC wrappers around these ActiveX controls so that you can use them in C++.  We do not recommend using these auto-generated wrappers but rather the wrappers that we have created specifically for our controls (i.e. for the CWGraph, the wrapper is CNiGraph).  Our wrappers are only available in VS 6, VS .NET 2003 and VS 2005 because those are the versions we currently support for C++. Because we don't support VS 2008, you will be using the auto-generated wrappers which again, I don't recommend.

Just for your information, we are planning on releasing VS 2008 C++ in Q4 of this year.  This puts our Beta target some time around the beginning of September. These dates are very preliminary and subject to change - we have only recently begun research on this project. 

So in the end, I would personally suggest you use VS 2005 for your C++ development and then migrate to VS 2008 when we provide native C++ support.

Best Regards,
Jonathan N.
National Instruments
0 Kudos
Message 9 of 25
(11,628 Views)

I have only been using 2008 on this machine.  What is the problem with VC wrappers?

 

0 Kudos
Message 10 of 25
(11,626 Views)