Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. DLL problem

DLL problem

Scheduled Pinned Locked Moved C / C++ / MFC
helpquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    Ghasrfakhri
    wrote on last edited by
    #1

    Dear Everybody I Want to make Dll file But The Exported Functions name have some prefix & post fix. if my Function name is Myproc its name show az ?abMyproc@@AXDCGFDFFD. How can I Fix it ? I'm Sorry For my English too :-O tancks. Iman Ghasrfakhri

    J 1 Reply Last reply
    0
    • G Ghasrfakhri

      Dear Everybody I Want to make Dll file But The Exported Functions name have some prefix & post fix. if my Function name is Myproc its name show az ?abMyproc@@AXDCGFDFFD. How can I Fix it ? I'm Sorry For my English too :-O tancks. Iman Ghasrfakhri

      J Offline
      J Offline
      Jorgen Sigvardsson
      wrote on last edited by
      #2

      In C++, names are mangled because of their polymorphic nature. Consider the functions

      void func(int x) { ... }
      void func(float x) { ... }

      . Clearly the name func is not enough as it is in C. C++ mangles the types involved into the name, resulting in "weird" names as the one you have discovered. However, functions may be exported with C linkage. This means that you get an unmangled name of that function in the librarys symbol table. It also means that you cannot use that name any longer for polymorphic functions. You should mark your function with an extern "C" clause. This MSDN link is a good starting point: ms-help://MS.MSDNQTR.2003FEB.1033/vclang/html/_pluslang_Linkage_to_Non.2d.C.2b2b_.Functions.htm[^] -- They're out get me, I can't escape cos' they won't let me They won't forget me, they'll get me in their grip and sweat me They'll wait me out, and then move in under my skin They'll make me doubt, they're out to make me let them in

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups