D
dwqxj
Unregistered / Unconfirmed
GUEST, unregistred user!
procedure TForm1.Button1Click(Sender: TObject);
var
eclapp:variant;
xlsFileName:string;
begin
xlsFileName:='c:/ex.xls';
eclApp:=CreateOleObject('Excel.Application');
eclApp.WorkBooks.Open(xlsfilename );
eclApp.WorkSheets[1].Activate;
edit1.text:=eclapp.cells(3,1).value;
//edit1.text:=eclapp.cells(3,1);
eclApp.WorkBooks.Close;
eclApp.Quit;
end;
错误提示:找不到成员
var
eclapp:variant;
xlsFileName:string;
begin
xlsFileName:='c:/ex.xls';
eclApp:=CreateOleObject('Excel.Application');
eclApp.WorkBooks.Open(xlsfilename );
eclApp.WorkSheets[1].Activate;
edit1.text:=eclapp.cells(3,1).value;
//edit1.text:=eclapp.cells(3,1);
eclApp.WorkBooks.Close;
eclApp.Quit;
end;
错误提示:找不到成员