用TWordapplication将已存在的WORD文档如:'D:/AA.DOC'加进去时Wordapplication1.Documents.ADD(??);

  • 主题发起人 主题发起人 kuilou
  • 开始时间 开始时间
K

kuilou

Unregistered / Unconfirmed
GUEST, unregistred user!
用TWordapplication将已存在的WORD文档如:'D:/AA.DOC'加进去时Wordapplication1.Documents.ADD(??);这参数怎样定??(20分)<br />用TWordapplication将已存在的WORD文档如:'D:/AA.DOC'加进去时
Wordapplication1.Documents.ADD(??);这参数怎样定??
然后WordDocument1.ConnectTo(??);这参数又怎样定??
 
procedure TForm1.open1Click(Sender: TObject);
var
Itemindex, format,TempEmpty: olevariant;
filename, passworddocument, passwordtemplate: olevariant;
writepassworddocument, writepasswordtemplate: olevariant;
confirmconversions, readonly, revert, addtorecentfiles: olevariant;
begin
filename:='c:/temp.DOC';
confirmconversions := false;
readonly := false;
addtorecentfiles := false;
revert := true;
passworddocument := '';
passwordtemplate := '';
writepassworddocument := '';
writepasswordtemplate := '';
format := wdopenformatdocument;
wordapplication1.documents.open(filename, confirmconversions,
readonly, addtorecentfiles, passworddocument, passwordtemplate,
revert, writepassworddocument, writepasswordtemplate, format,TempEmpty,TempEmpty);
end;
 
后退
顶部