The Y-axis is required for a Data Statistical Chart. The Statistical Chart is as follows:
MschartSource code
Mschart source code
1 <Asp: Chart id = " Chart1 " Runat = " Server " Width = " 700px " Height = " 300px " > 2 <Series> 3 <Asp: series name = " Series1 " Charttype = " Column " Borderwidth = " 1 " Shadowoffset = " 1 " Isvalueshownaslabel = " True " 4 Isvisibleinlegend = " True " Markerstyle = " Circle " > 5 </ASP: Series> 6 <Asp: series name = " Series2 " Charttype = " Column " Borderwidth = " 1 " Shadowoffset = " 1 " Isvalueshownaslabel = " True " 7 Isvisibleinlegend = " False " > 8 </ASP: Series> 9 </Series> 10 <Chartareas> 11 <Asp: chartarea name = " Chartarea1 " > 12 <Axisy linecolor = " 64, 64, 64 " Islabelautofit = " False " > 13 <Labelstyle/> 14 <Majorgrid linecolor = " 64, 64, 64 " /> 15 </Axisy> 16 <Axisy2 linecolor = " 64, 64, 64 " Islabelautofit = " False " > 17 <Labelstyle/> 18 <Majorgrid linecolor = " 64, 64, 64 " /> 19 </Axisy2> 20 </ASP: chartarea> 21 </Chartareas>22 </ASP: Chart>
BackgroundCode:
Background code
1 This . Chart1.datasource = DT; 2 This . Chart1.series [ 0 ]. Yaxistype = System. Web. UI. datavisualization. charting. axistype. Primary; 3 This . Chart1.series [ 0 ]. Xaxistype =System. Web. UI. datavisualization. charting. axistype. Primary; 4 This . Chart1.series [ 0 ]. Xvaluemember = " Supplyname " ; 5 This . Chart1.series [ 0 ]. Yvaluemembers = " Cgsumprice " ; 6 This . Chart1.series [ 0 ] [ " Pointwidth " ] = " 0.2 " ; 7 This . Chart1.series [ 1 ] [ " Pointwidth " ] =" 0.2 " ; 8 This . Chart1.series [ 0 ] [ " Drawingstyle " ] = " Cylinder " ; 9 This . Chart1.series [1 ] [ " Drawingstyle " ] = " Cylinder " ; 10 This . Chart1.chartareas [ 0 ]. Axisy. Title = " Purchase amount (RMB) " ; 11 This . Chart1.chartareas [ 0 ]. Axisy2.title = " Transaction count (times) " ; 12 This . Chart1.series [ 1 ]. Xaxistype = System. Web. UI. datavisualization. charting. axistype. Primary; 13 This . Chart1.series [ 1 ]. Yaxistype =System. Web. UI. datavisualization. charting. axistype. Secondary; 14 This . Chart1.series [ 1 ]. Yvaluemembers = " Jylcount " ; 15 This . Chart1.databind ();