CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    May 1999
    Posts
    20

    Problem linking with a MFC DLL - enresolved external error

    Hi!

    I have a MFC DLL named SERVICES.DLL which contains
    several classes, some of them visible to the outside world using AFX_EXT_CLASS.

    I have another DLL named LAND.DLL which uses
    some of the exposed classes of SERVICES.DLL.
    This DLL also exposes classes via AFX_EXT_CLASS.

    The problem is that I can't link LAND.DLL - I get
    an error message saying "Unresolved External...Cxxx():~Cxxx()" where Cxxx is a class
    from SERVICES.DLL that IS NOT EXPORTED using
    AFX_EXT_CLASS.
    When I use AFX_EXT_CLASS on Cxxx everything
    works OK ( - but I don't want to expose Cxxx :-< )

    Any suggestions??

    Regards,
    Eyal.




  2. #2
    Join Date
    May 1999
    Location
    OR, USA
    Posts
    65

    Re: Problem linking with a MFC DLL - enresolved external error

    No, u will not be able to use class from SERVICES.DLL in LAND.DLL
    unless it is exported.
    If possible move your class to LAND.DLL and then u won't face this problem.




  3. #3
    Join Date
    May 1999
    Posts
    20

    Re: Problem linking with a MFC DLL - enresolved external error

    Maby I wasn't clear enough...

    I DON'T use the Cxxx class in the LAND.DLL!
    (another class uses it internally)

    The problem does not occur if I use SERVICES.DLL
    directly from my app - only when I'm using it
    from another DLL!

    Eyal.



  4. #4
    Guest

    Re: Problem linking with a MFC DLL - enresolved external error

    I've found that this error occurs most often when the header file for the internal class is inadvertently included in the header of the class with the AFX_EXT_CLASS macro. Try moving headers to CPP files where possible.

    A shot in the dark, but I hope it helps.

    - Anonymous :-)


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured