DBChart如何能随着数据变动而刷新?
用下面这些代码:
DBChart1->RefreshData();
Series1->XLabelsSource="";
Series2->XLabelsSource="";
Series1->YValues->ValueSource="";
Series2->YValues->ValueSource=""; //初始化DBChart1
ADOQChart->Close();
ADOQChart->Open();
Series1->DataSource=ADOQChart;
Series2->DataSource=ADOQChart;
Series1->XLabelsSource=ADOQChart->Fields->Fields[0]->FieldName;
Series2->XLabelsSource=ADOQChart->Fields->Fields[0]->FieldName;
Series1->YValues->ValueSource=ADOQChart->Fields->Fields[1]->FieldName;
Series2->YValues->ValueSource=ADOQChart->Fields->Fields[2]->FieldName;
Screen->Cursor=crDefault;