Autor Beitrag
Christoph Englmann
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 276



BeitragVerfasst: Do 21.04.05 17:35 
hallo,

hab d6 mit office97 und ne form mit:
ExcelApplication1
ExcelWorkbook1
ExcelWorksheet1

und folgenden Quellcode
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
//Excel starten
  flcid := GetUserDefaultLCID;
  ExcelApplication1.Connect;
  ExcelApplication1.Visible[flcid] := true;
  ExcelApplication1.UserControl := true;

//Arbeitsmappe erstellen und Verbindung herstellen
  ExcelApplication1.Workbooks.add(EmptyParam,flcid);
  ExcelWorkbook1.ConnectTo(ExcelApplication1.ActiveWorkbook);
  ExcelWorksheet1.ConnectTo(ExcelApplication1.activeSheet as _Worksheet);


Problem:
bei
ExcelApplication1.Workbooks.add(EmptyParam,flcid);
hängt sich das programm mit der fehlermeldung
"OLE error 8007DCD0"
auf.
wenn ich mit der Maus über den Wert von EmptyParam fahre wird mir
"error(-2147352572)"
an


kann mir jemand sagen, wo der fehler ist???


danke