Author Topic: Sharing data in dll with nasmx and golink  (Read 2225 times)

Offline avcaballero

  • Full Member
  • **
  • Posts: 130
  • Country: es
    • Abre los Ojos al Ensamblador
Sharing data in dll with nasmx and golink
« on: November 18, 2015, 04:38:30 PM »
Hello, I'm dealing with dlls. I stuck sharing data between dll and my process. I have done that using something similar to encapsulation on oop, creating a function in the dll we can call from our process and that tell us what is its value. Nevertheless I'd like to share data, using any switch in the dll. Any help, please?

Offline Bryant Keller

  • Forum Moderator
  • Full Member
  • *****
  • Posts: 360
  • Country: us
    • About Bryant Keller
Re: Sharing data in dll with nasmx and golink
« Reply #1 on: February 12, 2016, 06:40:46 PM »
You should be able to share variables in exactly the same way you share procedures. Using the EXPORT directive (or /export command for Golink) when linking your DLL. I think the reason this gets confusing is because of Microsoft's naming convention for GetProcAddress.. that's not "Get Procedure Address" (as it's usually interpreted) instead it's actually "Get Process Address".. Microsoft defines its purpose as "Retrieves the address of an exported function or variable from the specified dynamic-link library (DLL)." The bold section is important to remember. If you're using GoLink, I suggest taking a look at this page.


About Bryant Keller