Hi, I have Programmed a dll but it isn't runable on other copmputers.
the message "error at inizialisation..." appears.
that's the source:
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
this is a skeleton i got
Seems the same, except for "End DllEntry".
Hope it could help :)
B7
;--------------------------------------------------------------------------------------
; 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
is it oblicated to neme the entryfunction DDLEntry???
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.
Unfortunately, I forget how that detail is accomplished, but Icz describes it in his classic tut.
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
Hope it will help you
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
"/ENTRY:Test_Start"
That it was!
thanks a lot !