我这里给出了三种方法来调用文档
procedure TMainForm.Button2Click(Sender: TObject);
var
lInfo: INFO_YYCSYWXX.TDOC_KBBD1;
lContext: TContext;
cInfoURL: String;
lBizObject: TBizObject;
i: Integer;
begin
cInfoURL := 'Biz:\LZ\INFO_YYCSYWXX.Info';
//在功能环境找信息环境
for i:=0 to Context.ChildCount-1 do
try
if SysUtils.SameText(cInfoURL, (Context.Children.Owner as TInfo).BizClassURL.BizURL.URL) then
begin
lBizObject := Context.Children.Owner;
lContext := Context.Children;
end;
except
end;
lInfo := INFO_YYCSYWXX.TDOC_KBBD1.Create(lContext);
try
lInfo.ShowFormDoc;
finally
lInfo.Free;
end;
end;
procedure TMainForm.Button3Click(Sender: TObject);
var
lInfo: INFO_YYCSYWXX.TDOC_KBBD1;
begin