如何将窗体做成dll delphi的帮助里就有一个例子! 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 我的email addr [email protected] 这个例子够了吧?PAS文件:unit dll;interfaceusesWinTypes, Classes, Controls, StdCtrls,WinProcs,Graphics,Forms,Buttons,SysUtils;type Tpasswordform = class(TForm) Edit1: TEdit; Button1: TButton; private { Private declarations } public { Public declarations }end;function GetPassword(Password:string):Boolean;export;implementationuses Dialogs;{$R *.DFM}function GetPassword(Password:string):Boolean;varPasswordForm:TPasswordForm;beginResult:=False;PasswordForm:=TPasswordForm.Create(Application);trywith PasswordForm doif ShowModal=mrOK thenif UpperCase(Edit1.Text)<> UpperCase(Password)thenMessageDlg('InvalidPassword',mtWarning,[mbOK],0)elseResult:=True;finallyPasswordForm.Free;end;end;end.DPR文件:library dllform;uses SysUtils, Classes, dll in 'dll.pas' {passwordform}; exports getpassword;{$R *.RES}beginend. 在Delphi+mssql里的报表设计器的IIF为空怎么写? dxdbGrid 检索问题。。 获取局域网内的数据库服务器列表 用IDHTTP上传文件时,如何在上传工作中获取上传速度? 如何获得当前程序运行路径的问题 高分請教DBCHART的難題,在線等待ing. 一个SQL SERVER配置工具,可能对大家有用 你们说学编程是把object pascal学精,还是学delphi的操作,做些东西出来 如何在所画的直线上表示进度 十万火急,给300分,关于delphi的combobox控件? 错误"System has been illegally re-entered"是什么意思? 关于数据库
PAS文件:
unit dll;interfaceuses
WinTypes, Classes, Controls, StdCtrls,WinProcs,Graphics,Forms,Buttons,SysUtils;type
Tpasswordform = class(TForm)
Edit1: TEdit;
Button1: TButton;
private
{ Private declarations }
public
{ Public declarations }
end;
function GetPassword(Password:string):Boolean;export;
implementation
uses Dialogs;
{$R *.DFM}
function GetPassword(Password:string):Boolean;
var
PasswordForm:TPasswordForm;
begin
Result:=False;
PasswordForm:=TPasswordForm.Create(Application);
try
with PasswordForm do
if ShowModal=mrOK then
if UpperCase(Edit1.Text)<> UpperCase(Password)then
MessageDlg('InvalidPassword',mtWarning,[mbOK],0)
else
Result:=True;
finally
PasswordForm.Free;
end;
end;
end.DPR文件:
library dllform;uses
SysUtils,
Classes,
dll in 'dll.pas' {passwordform};
exports getpassword;
{$R *.RES}begin
end.