trying to compile a dll

This is a discussion on trying to compile a dll within the Windows Programming forums, part of the Platform Specific Boards category; I am trying to compile my first dll file. at home I tried with Borland Free Compiler, but do not ...

  1. #1
    Hobo
    Guest

    trying to compile a dll

    I am trying to compile my first dll file. at home I tried with Borland Free Compiler, but do not know the options to specify and can't find, if someone could tell me this also please let me know.

    Now at uni, i try to compile with visual C and am getting an error:

    :\temp\myproj\testdll.h(15) : error C2059: syntax error : 'string'

    this is the offending code

    #define MYLIBAPI extern "C" __declspec(dllexport)

    MYLIBAPI DWORD g_nResult;

    this is the method according to 'programming apps for windows' by Richter, p 689

    any help appreciated

  2. #2
    Registered User
    Join Date
    Sep 2001
    Posts
    156
    It all looks fine. Do you have "windows.h" included do declare DWORD ?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. need help to compile this into dll
    By monxxx in forum C Programming
    Replies: 1
    Last Post: 10-09-2006, 03:41 PM
  2. C++ .NET - "inconsistent dll linkage" - What's that?
    By BrianK in forum Windows Programming
    Replies: 2
    Last Post: 03-16-2004, 10:16 AM
  3. Calling a VB DLL w/ forms from C++ DLL
    By UW_COOP in forum C++ Programming
    Replies: 8
    Last Post: 06-30-2003, 09:04 AM
  4. really, really basic DLL use
    By geophyzzer in forum Windows Programming
    Replies: 6
    Last Post: 09-24-2002, 07:09 PM
  5. Dll question again. Reference to No-One
    By G'n'R in forum C Programming
    Replies: 0
    Last Post: 10-24-2001, 04:52 AM

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