Accessing API in BlitzMax

BlitzMax Forums/BlitzMax Beginners Area/Accessing API in BlitzMax

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

You shouldn't have to specify which DLL to take them from, they're automatically available (I think). You should just be able to define the functions in an Extern block, a lot like you would in a decls file in BlitzPlus.

Extern "win32"
	Function SendMessage:Int(hWnd:Int,MSG:Int,wParam:Int,lParam:Int) = "SendMessageA@16"
End Extern


...at the top of your code is the equivalent of (from memory here :P)

.lib "user32.dll"

SendMessage%(hWnd%,MSG%,wParam%,lParam%):"SendMessageA@16"