LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

ActiveX pie chart range limit

I have a problem with creating a pie chart using ActiveX that seems to be related to the range. When I give it a source of 8 cells (source 1) the pie chart works fine (Right Pie). If I give it 9 cells (source 2) the pie chart data has 9 series instead of the 1 it should have (Wrong Pie). If I go into Excel I can correct it manually. I have been using this sub VI for a while with no problems but always with fewer than 8 cells. 

I am using Excel 2007 version 12.

0 Kudos
Message 1 of 10
(4,673 Views)

bfeddeck-

Creating Pie Charts is a new feature in LabVIEW 2009.  They are relatively simple to use and you wouldn’t have to worry about the ActiveX protocols sending data to Excel.  Please take a look at the LabVIEW Help on Types of Graphs and Charts.

Regards,

Mike S
NI AE
0 Kudos
Message 2 of 10
(4,638 Views)
I am able to create a pie chart with Labview, my problem is with Excel & ActiveX.
0 Kudos
Message 3 of 10
(4,629 Views)

bfeddeck-

After a little searching, I found a few links that may be helpful for you.  Please take a look.

KnowledgeBase Article: Using National Instruments Software to Control Microsoft Excel with ActiveX 

NI Developer Zone: Integrating Microsoft Excel with National Instruments Software 

Regards,

Mike S
NI AE
0 Kudos
Message 4 of 10
(4,620 Views)
Thanks, but I have read them before. I have search through the Excel ActiveX documents and can't find where there is a limit to how many cells can be selected.
0 Kudos
Message 5 of 10
(4,609 Views)
bfeddeck-

Have you tried using the Report Generation Toolkit?  Do you see the same behavior with those VIs?
Regards,

Mike S
NI AE
0 Kudos
Message 6 of 10
(4,587 Views)
I did try the Report Generation toolkit but it was a few years ago. I went to ActiveX to get more control of the way the report looked. I have attached an Excel file that shows the type of report I am making. The "Pie Charts" sheet is where I am having the problem. This is a good report.
0 Kudos
Message 7 of 10
(4,556 Views)

Hi bfeddeck,

 

I'm slightly confused about which range you are referring to? Is it one of the input to the subVI or is it one of the parameters within the subVI?

0 Kudos
Message 8 of 10
(4,527 Views)
Attached is part of the sub-vi where I am having the problem. I tell Excel which cells to use for the pie chart. If I use "Source 1" (8 cells) the pie chart is created successfully. If I use "Source 2" (14 cells) the pie chart only uses the first cell. I can go to the Excel file and select all 14 cells manually and the pie chart displays correctly. I also tried 9 cells with no luck, it seems that 8 cells are the limit. I am trying to find what is causing the limitation. I have also attached the sub-vi. 
Download All
0 Kudos
Message 9 of 10
(4,513 Views)

Hi bfeddeck,

 

You might want to take a look at the Range properties of the Excel._Worksheet class here. All LabVIEW does is communicate with the class and passes parameters to and from it. Detailed help about the method can be found on Microsoft's site.

0 Kudos
Message 10 of 10
(4,494 Views)