Author Topic: How to use the dll files of the open source library?  (Read 549 times)

Offline hu.tmx

  • Shy artist
  • Posts: 1
How to use the dll files of the open source library?
« on: October 29, 2016, 09:28:47 »
Hello All,

This might be a very newbie question to many of you. From lib.openmpt.org it is possible to get the compiled binaries (as well as source code) for openmpt.
What I want to do, is that I wanna make an Excel VBA script to be able to play modplug music. I tried putting a reference to the DLL files but it did not work (says invalid library files). I know that DLL files contain binary program data. And in many other cases I just put a reference on the dll file and then I can use its implemented functions. But now I'm not sure which way to go.

I kindly ask for some advice on how to get started really.

Cheers,
Thomas

Offline Saga Musix

  • OpenMPT Developers
  • *****
  • Posts: 6,108
  • aka Jojo
    • Download music, samples, VST plugins: Saga Musix Website
  • Operating System: Windows 7 x64
Re: How to use the dll files of the open source library?
« Reply #1 on: October 29, 2016, 11:52:23 »
I have no idea about VBA programming so I cannot help you with the details, but depending on whether Excel (or the scripting host, I don't know where VBA scripts are executed) is a 32-bit or 64-bit application, you will have to grab the appropriate 32-bit or 64-bit version. Also check which operating system you are running, as there are currently no binaries provided that are guaranteed to work on Windows Vista and older.
« Last Edit: October 29, 2016, 12:05:05 by Saga Musix »
ยป No support, bug reports, feature requests via private messages - they will not be answered. Use the forums and the issue tracker so that everyone can benefit from your post.

Offline LPChip

  • Administrator
  • *****
  • Posts: 4,935
    • http://lpchip.nl
  • Operating System: Windows 7 (x64bit)
Re: How to use the dll files of the open source library?
« Reply #2 on: October 29, 2016, 11:58:20 »
VBA is an extended form of VBScript. It is capable of doing dll calls, but as Saga Musix explains, you need to make sure you use the right version of the dll. It has been many years since I did anything remotely like this though, so I can't be of any more help.
"Heh, maybe I should've joined the compo only because it would've meant I wouldn't have had to worry about a damn EQ or compressor for a change. " - Atlantis
"yes.. I think in this case it was wishful thinking: MPT is makng my life hard so it must be wrong" - Rewbs