OLE访问Excel,提示错误“Variant does reference to an automation object”我的具体代码如下:
procedure TForm1.Button1Click(Sender: TObject);
var
       mRow,mCol: Integer;
             i,j: Integer;
  ExcelApp,Sheet: Variant;
               X: TStringList;
begin
  ExcelApp.DisplayAlerts:=False;//禁止提示存盘
  X:=TStringList.Create;
  For i:=0 to FileListBox1.Items.Count-1 do
  begin
   ExcelApp.Workbooks.open(FileListBox1.Items[i]);//打开Excel文件
   Sheet:=ExcelApp.Worksheets[1];//建立Excel的Sheet
   ExcelApp.Worksheets[1].Activate;//激活Sheet1
   X.Add(Sheet.Cells[2,15]);
  end;  ExcelApp.Workbooks.Close;
  ExcelApp.Quit;end;错在哪里呐?