|
Thread: Dll
-
Mar 5th, 2001, 05:16 PM
#1
Thread Starter
Junior Member
Can someone be nice and explain me how to make a dll with MS Visual C++ 6 (step by step)
I know C++, Im a newbie with vb but i know how to call funtion from a alredy make dll (like mcisendstring in winmm) so be nice and explain to me
-
Mar 8th, 2001, 10:27 AM
#2
Retired VBF Adm1nistrator
Sorry,
You're too polite.
You have to be more obnoxious and demanding 
- jamie
Microsoft MVP : Visual Developer - Visual Basic [2004-2005]
-
Mar 9th, 2001, 04:10 PM
#3
Hyperactive Member
ok:
1. open vc++
2. create a win32 dll project (no MFC), choose the "simple dll" option in the dialog that you get
3. make a function; it must be declared like this:
extern "C" <returntype> __stdcall <funcname>(params)
{
//code
}
then:
open notepad, and enter info like this:
LIBRARY "<dllname.dll>"
EXPORTS
<Function1>
<Function2>
just list all the functions you want to export.
save this as "<projectname>.def" and then in vc++ go to Project->Add to Project->Files
and add your DEF file. then compile, and you should be able to call the functions from VB 
There are other ways than using a DEF file, but I find this works, and it's not very complex to do.
buzzwords are the language of fools
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|