各位大哥们,麻烦帮小弟看看啊,找了半天的原因都没有找到......<br>以下是library的源码:<br>library Certificate;<br><br>{ Important note about DLL memory management: ShareMem must be the<br> first unit in your library's USES clause AND your project's (select<br> Project-View Source) USES clause if your DLL exports any procedures or<br> functions that pass strings as parameters or function results. This<br> applies to all strings passed to and from your DLL--even those that<br> are nested in records and classes. ShareMem is the interface unit to<br> the BORLNDMM.DLL shared memory manager, which must be deployed along<br> with your DLL. To avoid using BORLNDMM.DLL, pass string information<br> using PChar or ShortString parameters. }<br><br>uses<br> sharemem,<br> SysUtils,<br> Windows,<br> Forms,<br> ADODB,<br> UFrm_certificate in 'UFrm_certificate.pas' {Frm_certificate},<br> UFrm_export_list in 'UFrm_export_list.pas' {Frm_export_list},<br> define in '../define/define.pas',<br> UFrm_Contract in 'UFrm_Contract.pas' {Frm_Contract},<br> UFrmPasswordDlg in 'UFrmPasswordDlg.pas' {FrmPasswordDlg};<br><br>{$R *.res}<br>var<br> DllApplication: TApplication;<br> DllScreen: TScreen;<br><br>procedure ShowCertificateEx(ModuleID, ID, CateID: string; q_view: TADOQuery; Options: string);<br>begin<br> Frm_Certificate := TFrm_Certificate.Create(application, ModuleID, ID, q_view,Options);<br>end;<br><br>procedure ShowExportListEx(ModuleID, ID, CateID: string; q_view: TADOQuery; Options: string);<br>begin<br> Frm_export_list := TFrm_export_list.Create(application, ModuleID, ID, q_view,Options);<br>end;<br><br>procedure ShowContractEx(ModuleID, ID, CateID: string; q_view: TADOQuery; Options: string);<br>begin<br> Frm_Contract := TFrm_Contract.Create(application, ModuleID, ID, q_view,Options);<br>end;<br><br><br><br><br>procedure LibraryProc(Reason: Integer);<br>begin<br> if Reason = DLL_PROCESS_DETACH then<br> begin<br> Screen := DllScreen;<br> Application := DllApplication;<br> end;<br>end;<br>exports<br> ShowCertificateEx,ShowExportListEx,ShowContractEx; <br><br>begin<br> DllApplication := Application;<br> DllScreen := Screen;<br> DLLProc := @LibraryProc;<br>end.