336x280(권장), 300x250(권장), 250x250, 200x200 크기의 광고 코드만 넣을 수 있습니다.
implementation
{$R *.dfm}
procedure TForm1.Button1Click(Sender: TObject);
var ////동적 dll 만들기..
iDllHandle : Integer;
DllFunc : Function (a, b : Integer): Integer; //해당 함수 레퍼런스 가지고 있게.
begin
iDllHandle := LoadLibrary('dll1.dll'); //dll 파일 호출
if iDllHandle >= 32 then begin ////32미만은 에러다.메모리에 올리기.
@DllFunc := GetProcAddress(iDllHandle, 'Sum');//@는포인터로 바꿈
if @DllFunc <> Nil then
ShowMessage(IntToStr(DllFunc(1, 2)));
FreeLibrary(iDllHandle);////dll 메모리 해제
end;
end;
'컴터 > delphi' 카테고리의 다른 글
dll 만들기 기초 (0) | 2007.12.10 |
---|---|
TQuery의 묵시적 transaction 을 줄이기 위해.(cachedUpdate : false => true 로 전환) (0) | 2007.11.29 |
BDE > Query(DBTables) 사용시 (0) | 2007.11.29 |
북마크 (0) | 2007.11.28 |