J
jiangzhang3942
Unregistered / Unconfirmed
GUEST, unregistred user!
我写了下面的代码
procedure TForm1.Button1Click(Sender: TObject);
var
openfilename : string;
begin
OpenFileName := 'c:/book1.xls';
OleContainer1.CreateObjectFromFile(OPenFileName,FALSE);
OleContainer1.DoVerb(ovShow);
MExceL:=OleContainer1.OleObject;
MExceL.Application.CommandBars['Standard'].Visible:= False;
MExceL.Application.CommandBars['Formatting'].Visible:=false;
MExceL.application.ActiveSheet.Preview;
end;
时报错请问打印预览的那句代码怎么写呀
procedure TForm1.Button1Click(Sender: TObject);
var
openfilename : string;
begin
OpenFileName := 'c:/book1.xls';
OleContainer1.CreateObjectFromFile(OPenFileName,FALSE);
OleContainer1.DoVerb(ovShow);
MExceL:=OleContainer1.OleObject;
MExceL.Application.CommandBars['Standard'].Visible:= False;
MExceL.Application.CommandBars['Formatting'].Visible:=false;
MExceL.application.ActiveSheet.Preview;
end;
时报错请问打印预览的那句代码怎么写呀