• 大小: 4.8MB
    文件类型: .rar
    金币: 2
    下载: 0 次
    发布日期: 2024-01-01
  • 语言: C#
  • 标签: winform  chart  跟进式  

资源简介

winform chart动态跟进式折线图

资源截图

代码片段和文件信息

#include “MyForm.h“
#include 
using namespace chart_display;
[STAThread]        //单线程特性,有些组件要求单线程
int main(array^args)
{
Application::EnableVisualstyles(); //启用可视化界面,不然会很难看
Application::Run(gcnew MyForm()); //创建一个窗体,并进入消息循环

return 0;
}

System::Void MyForm::Show_Result(System::object^  sender System::EventArgs^  e)
{
//timer1->Interval = 10000;
chart1->ChartAreas[“ChartArea1“]->AxisX->Labelstyle->Format = “HH:mm:ss“;


}
System::Void MyForm::timer1_Tick(System::object^  sender System::EventArgs^  e)
{

Random^ random = gcnew Random;
//DateTime dt = DateTime::Now;
//String^ str = dt.ToString();
chart1->Series[“FUCK“]->Points->AddXY(DateTime::Now.ToString(“hh:mm:ss“) random->Next(0 1000));
chart1->ChartAreas[“ChartArea1“]->AxisX->Interval = 1;
chart1->ChartAreas[“ChartArea1“]->AxisX->ScaleView->Size = 8;
if (chart1->Series[“FUCK“]->Points->Count <= chart1->ChartAreas[“ChartArea1“]->AxisX->ScaleView->Size)
chart1->ChartAreas[“ChartArea1“]->AxisX->ScaleView->Position = 1;
else
chart1->ChartAreas[“ChartArea1“]->AxisX->ScaleView->Position = chart1->Series[“FUCK“]->Points->Count - chart1->ChartAreas[“ChartArea1“]->AxisX->ScaleView->Size;
textBox1->Text = System::Convert::ToString(chart1->Series[“FUCK“]->Points->Count);


/*while (chart1->Series[“热值“]->Points->Count > 10)
{
chart1->Series[“热值“]->Points->RemoveAt(0);
}
chart1->ChartAreas[“ChartArea1“]->AxisX->Minimum = chart1->Series[“热值“]->Points[0]->XValue;
chart1->ChartAreas[“ChartArea1“]->AxisX->Maximum = chart1->Series[“热值“]->Points[0]->XValue + 10;*/
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件       4472  2015-12-08 19:29  chart_display\chart_display\chart_display.vcxproj

     文件       1205  2015-12-08 19:29  chart_display\chart_display\chart_display.vcxproj.filters

     文件        165  2015-12-08 09:58  chart_display\chart_display\chart_display.vcxproj.user

     文件       3112  2015-12-31 10:39  chart_display\chart_display\Debug\.NETframeworkVersion=v4.5.AssemblyAttributes.obj

     文件       1898  2015-12-31 10:39  chart_display\chart_display\Debug\chart_display.Build.CppClean.log

     文件       2455  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.log

     文件        180  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.MyForm.resources

     文件        178  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.tlog\chart_display.lastbuildstate

     文件       2922  2015-12-31 15:50  chart_display\chart_display\Debug\chart_display.tlog\chart_display.write.1u.tlog

     文件       3572  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.tlog\cl.command.1.tlog

     文件       3948  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.tlog\CL.read.1.tlog

     文件        886  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.tlog\CL.write.1.tlog

     文件       1230  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.tlog\link.command.1.tlog

     文件       2094  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.tlog\link.read.1.tlog

     文件        532  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.tlog\link.write.1.tlog

     文件        282  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.tlog\metagen.read.1.tlog

     文件        282  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.tlog\metagen.write.1.tlog

     文件     248479  2013-03-01 23:21  chart_display\chart_display\Debug\chart_display.tlog\MYSQL.DATA.DLL.metagen

     文件          0  2015-12-31 10:39  chart_display\chart_display\Debug\chart_display.tlog\TZRES.DLL.bi

     文件        905  2015-12-31 10:42  chart_display\chart_display\Debug\chart_display.vcxproj.GenerateResource.Cache

     文件       9052  2015-12-31 10:39  chart_display\chart_display\Debug\chart_display.vcxprojResolveAssemblyReference.cache

     文件      25076  2015-12-31 10:42  chart_display\chart_display\Debug\MyForm.obj

     文件      86016  2015-12-31 10:42  chart_display\chart_display\Debug\vc120.pdb

     文件       1676  2015-12-31 10:42  chart_display\chart_display\MyForm.cpp

     文件       7471  2015-12-31 10:42  chart_display\chart_display\MyForm.h

     文件       6184  2015-12-31 10:42  chart_display\chart_display\MyForm.resx

     文件   29753344  2015-12-31 15:50  chart_display\chart_display.sdf

     文件        985  2015-12-08 09:53  chart_display\chart_display.sln

    ..A..H.     37376  2015-12-31 15:50  chart_display\chart_display.v12.suo

     文件      48640  2015-12-31 10:42  chart_display\Debug\chart_display.exe

............此处省略11个文件信息

评论

共有 条评论