Cannot see vertical line in OWC10

E

Eric Zhao

I have a OWC10 line chart.
The categories are a, b, c, d and the values are 5, 10, 15 and 25. The
chart works fine. However, the real world data for categories are b, b, b,
b. When it is ploted, it only show the first spot (b,5). I was expecting to
see a vertical line.

Please help!

Below is my sample code:

<HTML>
<BODY>
<OBJECT CLASSID="clsid:0002E500-0000-0000-C000-000000000046"
id=ChartSpace1></OBJECT>

<script language=vbscript>
Option Explicit

Sub Window_onLoad()

Dim c, oChart, oSer1

Set c = ChartSpace1.Constants

Set oChart = ChartSpace1.Charts.Add
oChart.Type = c.chChartTypeLineMarkers
oChart.HasLegend = True

Set oSer1 = oChart.SeriesCollection.Add '"d" is omitted for this series.
oSer1.SetData c.chDimSeriesNames, c.chDataLiteral, "Series #1"

oSer1.SetData c.chDimValues, c.chDataLiteral, Array(5, 10, 15, 25)
'oSer1.SetData c.chDimCategories, c.chDataLiteral, Array("a", "b", "c",
"d")

'comment out previous line, and un-comment the next line
'I was expect to see a verticle line at point b from 5 to 25

oSer1.SetData c.chDimCategories, c.chDataLiteral, Array("b", "b", "b",
"b")


End Sub

</script>

</BODY>
</HTML>
 
W

Wei-Dong XU [MSFT]

Hi Eric,

So far as I know, this is one expected behavior of OWC10 & OWC11. One
workaround as I know is you can perform some modifiction for the value to
make them different. For example, change the Array("b", "b", "b", "b") to
Array("b1", "b2", "b3", "b4") . Then the graph will displayed instead of
one point.

Please feel free to let me know if you have any question.

Best Regards,
Wei-Dong Xu
Microsoft Product Support Services
Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 
E

Eric Zhao

Do you know any other product be good substitute of OWC? I know it works
well in Excel, the only problem with me is that I need to display the chart
 
A

Alvin Bruney [MVP]

have a look at dundas, .netcharting, chartfx they go from about 500 to 1000
bucks a pop.
 
W

Wei-Dong XU [MSFT]

Hi Zhao,

It is recommended by Microsoft for your chart development with OWC chart
control. If you want to select other one, from my view, I'd introduce one
.Net component and one ActiveX control.
Open Source Charting & Reporting Tools in C#
http://csharp-source.net/open-source/charting-and-reporting

TeeChart
http://www.steema.com/

In addition, there are lots of chart controls (commercial or free). You can
feel free to pick them up. Google will help you to locate them.

However, please note: the two components are thrid-party, if there is any
technical problem during your development on them, you will need to contact
the support engineer of these companies.

Please feel free to let me know if you have any question.

Best Regards,
Wei-Dong Xu
Microsoft Product Support Services
Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top