1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Help needed in C++ DLL creation

Discussion in 'C++' started by sanjay_thakkar, May 30, 2009.

  1. sanjay_thakkar

    sanjay_thakkar New Member

    Joined:
    May 30, 2009
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    0
    Hi
    i am new to C++ but old to other programming langagues
    I need help in creating a DLL which in turn open a dialog box
    I have attached an Sample code which is similar i want in DLL when a DLL is called from my other program it will open a browse windows and then select the file and return back the file name
    Only difference is this program i have attached is like and EXE where as i require
    and DLL of the same prorgame

    Kindly help
    Thanks in Advance

    Sanjay
     

    Attached Files:

  2. xpi0t0s

    xpi0t0s Mentor

    Joined:
    Aug 6, 2004
    Messages:
    3,012
    Likes Received:
    203
    Trophy Points:
    0
    Occupation:
    Senior Support Engineer
    Location:
    England
    A DLL is similar to a static library; it doesn't need a main function and you need to use different linker flags when linking the code, to specify that it should be a DLL instead of an EXE. You'll need to read your linker documentation to find out how to do that.

    So you shouldn't ever be able to link DLL code successfully as an EXE; you should always get an "undefined symbol: main" error.
     

Share This Page