如何使mschart中绘制的线条变粗
How to make line plotted thicker in mschart
我有一条连接不同点的线。我已经动态生成了该行。我想让线条思考者。
我的代码如下:
//now lets plot lines between tow points.
Series newLineSeries = new Series("LineSeries" + index);
//--If the series already present lets remove from the chart
if(chart1.Series.IndexOf(newLineSeries.Name) != -1)
{
chart1.Series.RemoveAt(chart1.Series.IndexOf(newLineSeries.Name));
}
newLineSeries.ChartType = SeriesChartType.Line;
newLineSeries.MarkerBorderWidth.Equals(15);
newLineSeries.MarkerSize.Equals(35);
newLineSeries.Color = menuStripNodeInfoValues[index].colorValue;
newLineSeries.ToolTip = tooltipString;//tooltipString is cal. dynamically
newLineSeries.Points.Add(new DataPoint(valueX1,valueY1)); //valueX1,valueY1 are some dynamically calculated values
newLineSeries.Points.Add(new DataPoint(valueX2,valueY2));//These are also also dynamically calculated
chart1.Series.Add(newLineSeries);
这成功生成了一条线,但是即使我更改了 MarkerSize,线的大小也没有改变 属性。
你试过了吗chart1.Series[i].BorderWidth = 5
?如果按尺寸你的意思是厚度
我有一条连接不同点的线。我已经动态生成了该行。我想让线条思考者。 我的代码如下:
//now lets plot lines between tow points.
Series newLineSeries = new Series("LineSeries" + index);
//--If the series already present lets remove from the chart
if(chart1.Series.IndexOf(newLineSeries.Name) != -1)
{
chart1.Series.RemoveAt(chart1.Series.IndexOf(newLineSeries.Name));
}
newLineSeries.ChartType = SeriesChartType.Line;
newLineSeries.MarkerBorderWidth.Equals(15);
newLineSeries.MarkerSize.Equals(35);
newLineSeries.Color = menuStripNodeInfoValues[index].colorValue;
newLineSeries.ToolTip = tooltipString;//tooltipString is cal. dynamically
newLineSeries.Points.Add(new DataPoint(valueX1,valueY1)); //valueX1,valueY1 are some dynamically calculated values
newLineSeries.Points.Add(new DataPoint(valueX2,valueY2));//These are also also dynamically calculated
chart1.Series.Add(newLineSeries);
这成功生成了一条线,但是即使我更改了 MarkerSize,线的大小也没有改变 属性。
你试过了吗chart1.Series[i].BorderWidth = 5
?如果按尺寸你的意思是厚度