Measurement Studio for VC++

cancel
Showing results for 
Search instead for 
Did you mean: 

how to use NiGraph control component in the MFC not measurement studio MFC??

I want to use the NiGraph control component in the normal MFC(exe) program, but after you add the component to the project ,it will generate a CCWGraph class, and it doesnt work. If I want to use NiGraph class to plot data, What should I do? Help
Thanks a lot!!!
0 Kudos
Message 1 of 7
(4,401 Views)
Hi,

First off, what exactly do you mean by it's not working? Does it give you an error, unexpected results, etc?

What I suggest you do is take a look at some of the examples that ship with Measurement Studio. The following path is the default path for an example program using Measurement Studio graphs in Visual C++ .Net.

C:\Program Files\National Instruments\MeasurementStudioVS2003\VCNET\Examples\UI\Graph\Graph Example

Also, what might be easier is if you start out if a Measurement Studio Visual C++ MFC project as opposed to just a Visual C++ MFC project and then trying to add the Measurement Studio components. By starting with a Measurement Studio project it automatically takes care of some of the overheads related to adding components.
0 Kudos
Message 2 of 7
(4,383 Views)
I just a Visual C++ MFC project and then trying to add the Measurement Studio components,But there's something wrong and I can't figure it out.It generate the wrap class when I add the components,but it can't be useful. How can I change the CW-class to CNI-class properly ?? Can you see this project ? Thanks alot!

Message Edited by chinasymba on 06-06-2005 08:02 PM

0 Kudos
Message 3 of 7
(4,380 Views)
First try deleting the wrapper generated files from your folder (the files prefixed with cw). Then use the mstudio Add/Remove components wizard to add the CNi classes to your project. You will find this tool on your toolbar. When the dialog pops up, select the User Interface item. The next time you launch the class wizard, it should let you pick the CNi classes instead of asking you to generate the wrappers.

Hope this helps
Bilal Durrani
NI
0 Kudos
Message 4 of 7
(4,372 Views)
Dear Bilal Durrani
You mentioned using "the mstudio Add/Remove components wizard" to add the CNi classes to your project.But actually I cant find this "metudio" wizard, I only have the class wizard, so what is that wizard? Is that a icon in the toolbar?? I can't see it!? Can you give me a picture to show me how to find this "mstudio wizard"!!
Thanks a lot!!!
0 Kudos
Message 5 of 7
(4,354 Views)
I have attached an image of the toolbar items. If there items are not visible on your toolbar, right-click the toolbar, and select the item labeled "MStudio" (if using VC++ 6.0) or "NI-Measurement Studio" (if using VS 2003). These items will only be available if you have Measurement Studio support for C++ installed.

I hope this helps
Bilal Durrani
NI
0 Kudos
Message 6 of 7
(4,348 Views)
Dear Bilal Durrani
I suceed just as you told me!!! Thank you so much !!!
It's far away from enough to say thanks !!! 🙂
leo
0 Kudos
Message 7 of 7
(4,338 Views)