Dll Help

This is a discussion on Dll Help within the C++ Programming forums, part of the General Programming Boards category; I mostly program in C# and am having to create a C++ DLL for another project. I'm having problems with ...

  1. #1
    Registered User
    Join Date
    Dec 2002
    Posts
    9

    Question Dll Help

    I mostly program in C# and am having to create a C++ DLL for another project.

    I'm having problems with the function names of the dll becoming mangled after compilation.

    I have searched the newsgroups and only found to use the following line.

    #define EXPORT extern "C" __declspec (dllexport)
    EXPORT BOOL CALLBACK TESTFUNC();

    However, this is not working. The function names are still becoming mangled.

    I'm using Visual Studio .NET 2003.

    Any help is greatly appreciated!!

  2. #2
    Hardware Engineer
    Join Date
    Sep 2001
    Posts
    1,398
    This might be a dumb question, but did you tell Visual Studio to complie it as a DLL? (I'm not sure how to set this option.)

  3. #3
    Registered User
    Join Date
    Dec 2002
    Posts
    9
    It is set to compile as a dll.

    I created a DEF file and relinked and it seems to be working now.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. non-MFC DLL with MFC app question.
    By Kempelen in forum Windows Programming
    Replies: 10
    Last Post: 08-20-2008, 07:11 AM
  2. dll communicating between each other
    By cloudy in forum C++ Programming
    Replies: 5
    Last Post: 06-17-2005, 02:20 AM
  3. DLL and std::string woes!
    By Magos in forum C++ Programming
    Replies: 7
    Last Post: 09-08-2004, 12:34 PM
  4. Using class with DLL
    By greg2 in forum C++ Programming
    Replies: 2
    Last Post: 09-12-2003, 05:24 AM
  5. .lib vs .h vs .dll
    By Shadow12345 in forum C++ Programming
    Replies: 13
    Last Post: 01-01-2003, 04:29 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21