J
jb_slf123
Unregistered / Unconfirmed
GUEST, unregistred user!
用多线程加载ole怎么ole组件不显示(不提示错误),但不用多线程就能显示?另外,每次加载*.dwg ole对象能不能不打开autocad?
CoInitialize(nil);
try
form1.oledwg.Visible:=true;
if not form1.OpenDialog1.Execute then
Exit;
form1.oledwg.CreateLinkToFile(form1.OpenDialog1.FileName,false);
finally
CoUninitialize;
end;
CoInitialize(nil);
try
form1.oledwg.Visible:=true;
if not form1.OpenDialog1.Execute then
Exit;
form1.oledwg.CreateLinkToFile(form1.OpenDialog1.FileName,false);
finally
CoUninitialize;
end;