000
07.01.2005, 08:57 Uhr
~Tomm
Gast
|
Hallo zusammen,
vielleicht kann mir jemand helfen.
Bei folgendem Code erhalte ich immer eine Fehlermeldung
"Exception der Klasse EDatabaseError"
Meldung: "Eigenschaft TableName fehlt"
Ich komme leider nicht selber drauf woran es liegt.
Code:
//--------------------------------------------------------------------------- #include <vcl\vcl.h> //---------------------------------------------------------------------------- #include <vcl.h> #pragma hdrstop
#pragma link "Grids" #include "Unit100.h" //---------------------------------------------------------------------------- #pragma link "Grids" #pragma resource "*.dfm" TForm1 *Form1; //---------------------------------------------------------------------------- __fastcall TForm1::TForm1(TComponent *Owner) : TForm(Owner) { } //---------------------------------------------------------------------------- void __fastcall TForm1::FormShow(TObject *Sender) { TStringList *list = new TStringList(); TStringList *list1 = new TStringList();
Table1->Open(); DdeClientConv1->DdeService="VTPlus"; DdeClientConv1->DdeTopic="N-TV201"; DdeClientItem1->DdeConv= DdeClientConv1; DdeClientItem1->DdeItem=" 1,1,,,B(32/0/39/0)" ;
while(!Table1->Eof) { list1->Clear(); list1->Add(Table1->FieldByName("DATUM")->AsString); list1->Add(Table1->FieldByName("WERT")->AsString); list1->Add(Table1->FieldByName("VOLUME")->AsString); list->Add(list1->CommaText); Table1->Next(); list->SaveToFile("C:/Aktien/ 1000.txt"); }
} //---------------------------------------------------------------------------- void __fastcall TForm1:deClientItem1Change(TObject *Sender) { TStringList *list1 = new TStringList(); TStringList *list = new TStringList(); Table1->Filter = "WERT > 0"; Table1->Open(); Table1->Last(); if (Edit1->Text!= DdeClientItem1->Text) { Table1->Append(); Edit1->Text = DdeClientItem1->Text; Table1->FieldByName("WERT")->AsString = Edit1->Text; Table1->FieldByName("DATUM")->AsDateTime = ("dd.mm.yyyy",Date())+("hh:mm:ss", Time()); Table1->Post(); Table1->UpdateCursorPos(); list1->Clear(); list->LoadFromFile("C:/Aktien/ 1000.txt"); list1->Add(Table1->FieldByName("DATUM")->AsString); list1->Add(Table1->FieldByName("WERT")->AsString); list->Add(list1->CommaText); list->SaveToFile("C:/Aktien/ 1000.txt");
}if (Table1->FieldByName("WERT")->AsString ==" " ) { Table1->Delete() ; Table1->Post(); } }
//-------------------------------------------------------------------------
Gruß
Tomm |