Ich brauche Punkte Werte in Diagrammdiagramm angezeigt wird, wenn ich das Ergebnis versucht warwie Werte auf Diagramm Diagramm anzuzeigen
Aber ich will es wie
Mein Code ist
SqlCommand territorycommand = new SqlCommand("select Terriotry,TotalAcheivmentVol,Forecast from ForecastTotal where Year = '" + DateTime.Now.Year.ToString() + "' and Terriotry = '" + territory + "' and month = '"+Month+"'", conn);
try
{
conn.Open();
mydatareader = territorycommand.ExecuteReader();
while (mydatareader.Read())
{
chart1.Series["TotalAchievment"].Points.AddXY(mydatareader.GetString(0), mydatareader.GetInt32(1));
chart1.Series["Forecast"].Points.AddY(mydatareader.GetInt32(2));
chart1.ChartAreas[0].AxisX.LabelStyle.Interval = 1;
chart1.ChartAreas[0].AxisX.Interval = 1;
}
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
conn.Close();
Ist das möglich?
Haben Sie 'chart1.Series versucht [ "TotalAchievment"] = IsValueShownAsLabel true'.? – praty
thx es funktioniert^_^.. put ur antwort plz –