找回密码
 立即注册

QQ登录

只需一步,快速开始

deny_crack

银牌会员

5

主题

18

帖子

3061

积分

银牌会员

积分
3061

活字格认证

deny_crack
银牌会员   /  发表于:2012-11-8 12:46  /   查看:6756  /  回复:6

环境是ASP.NET WIJMO,我设置了
style = new ChartStyle();
style.StrokeWidth = 3;
C1CompositeChart1.SeriesStyles.Add(style);
没有效果
但是这样的处理方法在linechart里是可以的

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?立即注册

x

6 个回复

倒序浏览
deny_crack
银牌会员   /  发表于:2012-11-8 16:02:00
沙发
问题补充:如果是折线图,图例要怎么这是成折线图的图例,而不是这种色块?
回复 使用道具 举报
iceman
社区贡献组   /  发表于:2012-11-8 18:34:00
板凳
回复 2楼deny_crack的帖子

deny_crack 你好,
可以尝试把 C1Chart 的 ChartType 设置为 linechart ,看是否可行。
回复 使用道具 举报
deny_crack
银牌会员   /  发表于:2012-11-9 09:08:00
地板
你好
此处我设置的是line,代码如下:
s = new CompositeChartSeries();
s.Type = ChartSeriesType.Line;
style = new ChartStyle();
style.StrokeWidth = 3;
//数据处理
C1CompositeChart1.SeriesList.Add(s);
C1CompositeChart1.SeriesStyles.Add(style);
回复 使用道具 举报
deny_crack
银牌会员   /  发表于:2012-11-9 09:09:00
5#
补充:ChartSeriesType里好像没有linechart枚举
回复 使用道具 举报
iceman
社区贡献组   /  发表于:2012-11-9 15:40:00
6#
回复 1楼deny_crack的帖子

deny_crack 你好,
下面是设置 linechart 线条粗细的代码,style 作用域对应添加 series 的顺序。

  1. //Style1 对应 s1
  2.         ChartStyle style1 = new ChartStyle();
  3.         style1.StrokeWidth = 10;

  4.         //Style2 对应 s2
  5.         ChartStyle style2 = new ChartStyle();
  6.         style2.StrokeWidth = 1;

  7.         this.C1CompositeChart1.SeriesList.Add(s1);
  8.         this.C1CompositeChart1.SeriesList.Add(s2);
  9.         this.C1CompositeChart1.SeriesStyles.Add(style1);
  10.         this.C1CompositeChart1.SeriesStyles.Add(style2);
复制代码
回复 使用道具 举报
iceman
社区贡献组   /  发表于:2012-11-12 17:36:00
7#
回复 6楼iceman的帖子

Demo :

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
回复 使用道具 举报
您需要登录后才可以回帖 登录 | 立即注册
返回顶部