程序中发布OCX

 

在DPR文件中
program XXX;

uses
  Forms,Windows,
  uMainFM in ’uMainFM.pas’ {MainFM};

{$R *.RES}
Var
  hLib:THandle;
  PRegOcx: procedure ; stdcall;

begin
  Application.Initialize;
  hLib:=Loadlibrary(’C:\TIDESTONE\FORMONE6\ttf16.ocx’);
  PRegOcx:=GetProcAddress(hLib,PChar(’DllRegisterServer’));
  if Assigned(PRegOcx) then
    PRegOcx;

  Application.CreateForm(TMainFM, MainFM);
  Application.Run;
end.

相关信息
相关评论
相关文章
字母检索 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z