Clan x86

Technical (Development, Security, etc.) => General Programming => Tutorials, References, and Examples => Topic started by: Joe on November 25, 2005, 05:05:13 PM

Title: [VC++] DLL Demonstration!
Post by: Joe on November 25, 2005, 05:05:13 PM
Yeah, this took me a good hour or so to figure out. Sam's Teach Yourself VC++ in 21 Days was teaching me wrong =p.

I was trying to figure out how to export some simple functions, so that I could begin writing JBBECore.dll, to ease the eventual complete move to VC++ over VB. Anyhow, I exported the VC++ MessageBox(HWnd, LPCSTR, LPCSTR, UInt) function (its just a wrapper, but oh well?) and an Addition(int, int) function I wrote. I also have a VisualBasic program that will call MessageBox() with "Hello World", then call it again with the result of adding 1+1. The DLL tells you when a process attaches/detaches itself to you (thats the DLL itself, not VB). Full source code is included.

http://www.javaop.com/~joe/VC++/DLL.zip

EDIT -
Omg grammar fix.
Title: Re: [VC++] DLL Demonstration!
Post by: Palio on December 01, 2005, 12:34:23 PM
Isn't that the one you wrote for me?  :D
Title: Re: [VC++] DLL Demonstration!
Post by: Warrior on December 01, 2005, 03:46:51 PM
VC++ isn't a language.
Title: Re: [VC++] DLL Demonstration!
Post by: MyndFyre on December 01, 2005, 05:49:37 PM
Quote from: Warriorx86] link=topic=3916.msg41789#msg41789 date=1133470011]
VC++ isn't a language.
No, but it is a technology, and it is one that is difficult to figure out due to its sheer size.
Title: Re: [VC++] DLL Demonstration!
Post by: Warrior on December 01, 2005, 06:50:46 PM
Don't know how it can be considered a technology especially since all I see close to techical is thier dumb IDEs.
The only thing I see hard to figure out is Windows horrible and redundant API.
Christ why can't they just be like everyone else they got to do things thier way which most of the time ends up being the bad way to go.

Additionally I don't think preappending a topic name with a "Techonology" is very approriate especially when most of what he posted was standard C++ with some Windows libraries slapped on it.
Title: Re: [VC++] DLL Demonstration!
Post by: Joe on December 01, 2005, 07:21:43 PM
No Palio, I wrote the MathDLL specifically for you. =p