Linking Error !!

This is a discussion on Linking Error !! within the Windows Programming forums, part of the Platform Specific Boards category; Dear Members, I am using Microsoft Visual C++ 6.0 on Win 98 Platform. While Building my application using above compiler, ...

  1. #1
    Registered User
    Join Date
    Mar 2004
    Posts
    2

    Unhappy Linking Error !!

    Dear Members,
    I am using Microsoft Visual C++ 6.0 on Win 98 Platform.

    While Building my application using above compiler,
    i am getting the following Linking Errors :


    Linking.......
    nafxcwd.lib (thrdcore.obj) : error LNK2001 : unresolved external symbol __endthreadex
    nafxcwd.lib (thrdcore.obj) : error LNK2001 : unresolved external symbol __beginthreadex
    Debug/program1.exe : fatal error LNK1120 : 2 unresolved externals

    There were no compile time errors.
    Can u tell me what these mean, and how to resolve them???
    I am attaching source files in a zip file.
    I am stuck in my project due to this.

    Looking forward for your help,
    Thanking you,
    Mrprogrammer.
    Attached Files Attached Files

  2. #2
    Even death may die... Dante Shamest's Avatar
    Join Date
    Apr 2003
    Location
    Malaysia
    Posts
    970
    Linking code requiring the multithreaded libraries (any MFC code or code compiled with /MT) causes LNK2001 on _beginthread, _beginthreadex, _endthread, and _endthreadex. See the following Knowledge Base article for more information:
    Got that info from here:
    http://msdn.microsoft.com/library/de...ml/LNK2001.asp

  3. #3
    It's full of stars adrianxw's Avatar
    Join Date
    Aug 2001
    Posts
    4,831
    Change your project settings to link with the multithreaded libraries, by default it links with the single threaded libraries.

    Project->Settings->C/C++->Category Code Generation-> Runtime library to Multithreaded or Debug multithreaded as appropriate.
    Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Beginner Needs help in Dev-C++
    By Korrupt Lawz in forum C++ Programming
    Replies: 20
    Last Post: 09-28-2010, 01:17 AM
  2. Post...
    By maxorator in forum C++ Programming
    Replies: 12
    Last Post: 10-11-2005, 08:39 AM
  3. pointer to array of objects of struct
    By undisputed007 in forum C++ Programming
    Replies: 12
    Last Post: 03-02-2004, 03:49 AM
  4. Stupid compiler errors
    By ChrisEacrett in forum C++ Programming
    Replies: 9
    Last Post: 11-30-2003, 04:44 PM
  5. Couple C questions :)
    By Divx in forum C Programming
    Replies: 5
    Last Post: 01-28-2003, 12:10 AM

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