Hi, I have Programmed a dll but it isn't runable on other copmputers.

the message "error at inizialisation..." appears.

that's the source:


dll_begin PROC hInstDLL:HINSTANCE, reason:DWORD, reserved1:DWORD

MOV EAX, hInstDLL
MOV h_dll, EAX

MOV EAX, TRUE

RET
dll_begin ENDP
Posted on 2003-06-09 10:30:52 by Forginforcer
this is a skeleton i got




;--------------------------------------------------------------------------------------
; DLLSkeleton.asm
;--------------------------------------------------------------------------------------
.386
.model flat,stdcall
option casemap:none

extrn xxxx :proc


.data
.code

DllEntry PROC hInstDLL:DWORD, reason:DWORD, reserved:DWORD
[put initialization code here]
ret
DllEntry ENDP

SomeProc PROC
ret
SomeProc ENDP

PUBLICDLL SomeProc

End DllEntry


SAMPLE.DEF

LIBRARY Sample
EXPORTS
SomeProc


Seems the same, except for "End DllEntry".
Hope it could help :)

B7
Posted on 2003-06-10 01:42:26 by Bit7
is it oblicated to neme the entryfunction DDLEntry???
Posted on 2003-06-10 02:33:37 by Forginforcer
No it isn't. I always call mine DllMain. All that matters is the name is exported properly.

Unfortunately, I forget how that detail is accomplished, but Icz describes it in his classic tut.
Posted on 2003-06-10 06:58:16 by Ernie
You can name your dll's entry point any name as you want. The rules, (as what I know) to make it the dll's entry point, are

1. Add its name in the END stament. To make Test_Entry as the Dll's Entry, here's my code
.CODE


Func1 Proc
ret
Func1 EndP

Test_Entry Proc hInstance:Dword, reason:Dword, lpres:Dword
mov eax, 1
ret
Test_Entry EndP

[B]END Test_Start[/B]
2. Specify "/ENTRY:Test_Start" in the linker.

Hope it will help you
Posted on 2003-06-14 01:58:25 by rxbagain


"/ENTRY:Test_Start"

That it was!

thanks a lot !
Posted on 2003-06-14 02:50:15 by Forginforcer