2009年2月23日星期一
2009年2月17日星期二
2009年2月4日星期三
2009年1月21日星期三
2008年12月27日星期六
2008年10月26日星期日
openflashchart 2 .net添加了一个IHttpHandler
新添加的httphanlder,使得图形可以不再需要使用单独的数据文件。
使用方式,
1,web.config中添加
<httpHandlers>
<add verb="*" path="ofc_handler.ofc" type="OpenFlashChart.WebHandler.ofcHandler, OpenFlashChart"/>
</httpHandlers>
2,在数据生成的时候,把chart的示例赋予control中的Chart属性
具体见代码。
使用方式,
1,web.config中添加
<httpHandlers>
<add verb="*" path="ofc_handler.ofc" type="OpenFlashChart.WebHandler.ofcHandler, OpenFlashChart"/>
</httpHandlers>
2,在数据生成的时候,把chart的示例赋予control中的Chart属性
具体见代码。
ArrayList data1 = new ArrayList();
Random rand = new Random(DateTime.Now.Millisecond);
for (double i = 0; i < temp =" rand.Next(30);"> 20)
data1.Add(new LineDotValue(temp, "#fe0"));
else
{
data1.Add(temp);
}
}
OpenFlashChart.LineHollow line1 = new LineHollow();
line1.Values = data1;
line1.HaloSize = 0;
line1.Width = 2;
line1.DotSize = 5;
line1.Tooltip = "提示:#val#";
chart.AddElement(line1);
chart.Title = new Title("line演示");
chart.Y_Axis.SetRange(0, 35, 5);
chart.Tooltip = new ToolTip("全局提示:#val#");
chart.Tooltip.Shadow = true;
chart.Tooltip.Colour = "#e43456";
chart.Tooltip.MouseStyle = ToolTipStyle.CLOSEST;
OpenFlashChartControl1.EnableCache = false;
OpenFlashChartControl1.Chart = chart;
2008年10月10日星期五
VS设计时问题
| at System.ComponentModel.Design. at System.ComponentModel.Design. at System.ComponentModel.Design. at System.ComponentModel.Design. at System.ComponentModel.Design. VS应该是(猜测?) 例如下面的代码(部分) /// /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// private void InitializeComponent() { this.SuspendLayout(); // // button1 // this.button1.Location = new System.Drawing.Point(40, 86); …… this.ResumeLayout(false); } #endregion private System.Windows.Forms.Button button1= new System.Windows.Forms.Button(); button1变量在InitializeComponent函 因此,会给出错误(原则上说VS在这点上有点苛刻。), private void InitializeComponent() { button1 = new System.Windows.Forms.Button(); this.SuspendLayout(); // // button1 // this.button1.Location = new System.Drawing.Point(40, 86); …… this.ResumeLayout(false); } #endregion private System.Windows.Forms.Button button1;//= new System.Windows.Forms.Button(); 上面的错误的话,VS2008中还可以给出错误的行数( 也没法给出。 比如我在自定义控件里定义一个属性(Property) public string JustForTest { get { return ConfigurationManager. } set { Configuration config = ConfigurationManager. config.AppSettings.Settings[" config.Save( } } 这样的属性在运行时和设计时对这个控件来说也是没有问题的, 这个Form就会出现问题。 VS会自动的初始化这个控件的Public属性值, this.userControl11. 而在设计时,这个属性是无法获取的,错误产生。 VS还需要继续在设计时的支持方面努力啊 |
订阅:
博文 (Atom)


