将文本放在条形图上

编程入门 行业动态 更新时间:2024-10-07 08:24:43
本文介绍了将文本放在条形图上的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

嗨sipla和every1再次

hi sipla and every1 again

现在只在第一个范围栏中,除了右边的标签(显示的数量)我想在的中间放置一个自定义文本

now only in the first range bar besides label at right(amount shown) i want to place a custom text in the middle of

我在上面显示为"酒吧自定义文字"的栏...我该怎么办?帮助其它可能需要花费太多时间..

the bar which i showed above as 'custom text in bar'...how do i do? help else it may take too much time..

谢谢

推荐答案

一种选择是起诉StripLines。您可以使用Interval,Stripwidth和Interval偏移属性获得所需内容。

One option is to sue StripLines. You might get what you want using the Interval, Stripwidth and Interval offset attributes. <asp:ChartArea Name="ChartArea1" BorderColor="64, 64, 64, 64" BackSecondaryColor="White" BackColor="OldLace" ShadowColor="Transparent" BackGradientStyle="TopBottom"> <area3dstyle Rotation="10" Perspective="10" Inclination="15" IsRightAngleAxes="False" WallWidth="0" IsClustered="False" /> <axisy LineColor="64, 64, 64, 64" LabelAutoFitMaxFontSize="8"> <LabelStyle Font="Trebuchet MS, 8.25pt, style=Bold" Format="C0" /> <MajorGrid LineColor="64, 64, 64, 64" /> </axisy> <axisx LineColor="64, 64, 64, 64" LabelAutoFitMaxFontSize="8"> <LabelStyle Font="Trebuchet MS, 8.25pt, style=Bold" IsEndLabelVisible="False" Format="MM-dd" /> <MajorGrid LineColor="64, 64, 64, 64" /> <striplines> <asp:stripline StripWidth="1" Interval="1" IntervalOffset="0.5" BackColor="64, 191, 191, 191"></asp:stripline> </striplines> </axisx> </asp:ChartArea>

设置带状线文字的代码:

Code to set the stripline text:

StripLine stripLine = Chart1.ChartAreas["ChartArea1"].AxisX.StripLines[0]; stripLine.Text = "Whatever text you want";

希望这会有所帮助,

谢谢,

更多推荐

将文本放在条形图上

本文发布于:2023-07-18 08:09:49,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1142707.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:放在   条形   图上   文本

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!