Visual C++ 6.0 DLLs |
Author: |
Message: |
Spunky
Former Super Mod
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](http://i39.tinypic.com/345jujo.png)
Posts: 3658 Reputation: 61
36 / / ![United Kingdom Flag](images/flags/gb.png)
Joined: Aug 2006
|
O.P. Visual C++ 6.0 DLLs
I'm trying to make a DLL, but I keep getting "Cannot find entry point <function name> in <dllname>" errors. I've followed instructions from various website, but they all cause the same errors.
Can sombody zip up an example project for me so I can see where I'm going wrong?
<Eljay> "Problems encountered: shit blew up" ![:zippy:](images/smilies/zippy.gif)
|
|
09-21-2007 08:12 PM |
|
![](images/pixel.gif) |
ShawnZ
Veteran Member
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](avatar.php?uid=4387-14065)
Posts: 3146 Reputation: 43
32 / / ![Canada Flag](images/flags/ca.png)
Joined: Jan 2003
|
RE: Visual C++ 6.0 DLLs
what dll? one of yours or a system one?
This post was edited on 09-21-2007 at 08:16 PM by ShawnZ.
Spoiler: the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
the game.
|
|
09-21-2007 08:16 PM |
|
![](images/pixel.gif) |
Spunky
Former Super Mod
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](http://i39.tinypic.com/345jujo.png)
Posts: 3658 Reputation: 61
36 / / ![United Kingdom Flag](images/flags/gb.png)
Joined: Aug 2006
|
O.P. RE: Visual C++ 6.0 DLLs
I'm trying to make one of my own... I've made the .cpp, h and def files and followed the instructions given on website. The DLL makes ok, but I can't call it from within VB
<Eljay> "Problems encountered: shit blew up" ![:zippy:](images/smilies/zippy.gif)
|
|
09-21-2007 08:18 PM |
|
![](images/pixel.gif) |
vikke
Senior Member
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](avatar.php?uid=55246-6142)
Posts: 900 Reputation: 28
31 / / ![Sweden Flag](images/flags/se.png)
Joined: May 2006
|
RE: Visual C++ 6.0 DLLs
Are you sure your exported functions are in the def file?
They should be, then compile and copy to the same directory as your VB exe.
|
|
09-21-2007 08:32 PM |
|
![](images/pixel.gif) |
Spunky
Former Super Mod
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](http://i39.tinypic.com/345jujo.png)
Posts: 3658 Reputation: 61
36 / / ![United Kingdom Flag](images/flags/gb.png)
Joined: Aug 2006
|
O.P. RE: Visual C++ 6.0 DLLs
Yeah, they are definatley exported... I've seen a few sites say that I should do it
<Eljay> "Problems encountered: shit blew up" ![:zippy:](images/smilies/zippy.gif)
|
|
09-21-2007 08:33 PM |
|
![](images/pixel.gif) |
vikke
Senior Member
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](avatar.php?uid=55246-6142)
Posts: 900 Reputation: 28
31 / / ![Sweden Flag](images/flags/se.png)
Joined: May 2006
|
RE: Visual C++ 6.0 DLLs
Hmm.. They may be mangled by your compiler. To find out, download dependencywalker from www.dependencywalker.com, and open your DLL.
More information of name mangling here: http://en.wikipedia.org/wiki/Name_mangling
|
|
09-22-2007 07:21 AM |
|
![](images/pixel.gif) |
Spunky
Former Super Mod
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](http://i39.tinypic.com/345jujo.png)
Posts: 3658 Reputation: 61
36 / / ![United Kingdom Flag](images/flags/gb.png)
Joined: Aug 2006
|
O.P. RE: Visual C++ 6.0 DLLs
quote: Originally posted by vikke
Hmm.. They may be mangled by your compiler. To find out, download dependencywalker from www.dependencywalker.com, and open your DLL.
I checked it out in Dependency Walker and it appears to be ok...
Still notworking though =/
Attachment: error.PNG (38.42 KB)
This file has been downloaded 134 time(s).
<Eljay> "Problems encountered: shit blew up" ![:zippy:](images/smilies/zippy.gif)
|
|
09-22-2007 05:35 PM |
|
![](images/pixel.gif) |
vikke
Senior Member
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](avatar.php?uid=55246-6142)
Posts: 900 Reputation: 28
31 / / ![Sweden Flag](images/flags/se.png)
Joined: May 2006
|
RE: Visual C++ 6.0 DLLs
It is mangled. Click F10 in Dependency Walker to unmangle all function names.
If it wouldn't be mangled it would be:
This post was edited on 09-22-2007 at 09:43 PM by vikke.
|
|
09-22-2007 05:50 PM |
|
![](images/pixel.gif) |
Mnjul
forum super mod
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](avatar.php?uid=2749-11221)
plz wub me
Posts: 5396 Reputation: 58
– / / ![Taiwan Flag](images/flags/tw.png)
Joined: Nov 2002
Status: Away
|
RE: Visual C++ 6.0 DLLs
Does your DLL has a DllMain function?
|
|
09-22-2007 06:47 PM |
|
![](images/pixel.gif) |
Spunky
Former Super Mod
![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif) ![*](images/star.gif)
![Avatar](http://i39.tinypic.com/345jujo.png)
Posts: 3658 Reputation: 61
36 / / ![United Kingdom Flag](images/flags/gb.png)
Joined: Aug 2006
|
O.P. RE: Visual C++ 6.0 DLLs
code: BOOL APIENTRY DllMain( HANDLE hModule,
DWORD ul_reason_for_call,
LPVOID lpReserved
)
{
switch (ul_reason_for_call)
{
case DLL_PROCESS_ATTACH:
case DLL_THREAD_ATTACH:
case DLL_THREAD_DETACH:
case DLL_PROCESS_DETACH:
break;
}
return TRUE;
}
<Eljay> "Problems encountered: shit blew up" ![:zippy:](images/smilies/zippy.gif)
|
|
09-22-2007 08:34 PM |
|
![](images/pixel.gif) |
Pages: (2):
« First
[ 1 ]
2
»
Last »
|
|