Code/Resource
Windows Develop
Linux-Unix program
Internet-Socket-Network
Web Server
Browser Client
Ftp Server
Ftp Client
Browser Plugins
Proxy Server
Email Server
Email Client
WEB Mail
Firewall-Security
Telnet Server
Telnet Client
ICQ-IM-Chat
Search Engine
Sniffer Package capture
Remote Control
xml-soap-webservice
P2P
WEB(ASP,PHP,...)
TCP/IP Stack
SNMP
Grid Computing
SilverLight
DNS
Cluster Service
Network Security
Communication-Mobile
Game Program
Editor
Multimedia program
Graph program
Compiler program
Compress-Decompress algrithms
Crypt_Decrypt algrithms
Mathimatics-Numerical algorithms
MultiLanguage
Disk/Storage
Java Develop
assembly language
Applications
Other systems
Database system
Embeded-SCM Develop
FlashMX/Flex
source in ebook
Delphi VCL
OS Develop
MiddleWare
MPI
MacOS develop
LabView
ELanguage
Software/Tools
E-Books
Artical/Document
DynaForm.pas
Package: delphi.rar [view]
Upload User: fh681027
Upload Date: 2022-07-23
Package Size: 1959k
Code Size: 1k
Category:
Delphi VCL
Development Platform:
Delphi
- unit DynaForm;
- interface
- uses
- SysUtils, Windows, Messages, Classes, Graphics, Controls,
- Forms, Dialogs, StdCtrls, Spin;
- type
- TForm1 = class(TForm)
- Button1: TButton;
- Edit1: TEdit;
- Label1: TLabel;
- SpinEdit1: TSpinEdit;
- Label2: TLabel;
- procedure Button1Click(Sender: TObject);
- private
- { Private declarations }
- public
- { Public declarations }
- end;
- var
- Form1: TForm1;
- implementation
- {$R *.DFM}
- type
- TIntFunction = function (I: Integer): Integer; stdcall;
- const
- DllName = 'Firstdll.dll';
- procedure TForm1.Button1Click(Sender: TObject);
- var
- HInst: THandle;
- FPointer: TFarProc;
- MyFunct: TIntFunction;
- begin
- HInst := SafeLoadLibrary (DllName);
- if HInst > 0 then
- try
- FPointer := GetProcAddress (HInst,
- PChar (Edit1.Text));
- if FPointer <> nil then
- begin
- MyFunct := TIntFunction (FPointer);
- SpinEdit1.Value := MyFunct (SpinEdit1.Value);
- end
- else
- ShowMessage (Edit1.Text + ' DLL function not found');
- finally
- FreeLibrary (HInst);
- end
- else
- ShowMessage (DllName + ' library not found');
- end;
- end.