|
Post by matty47 on May 28, 2022 23:18:47 GMT -5
Does Liberty Basic have the ability to "map" functions called from an external dll to a name? or handle? For example could the following
Calldll #x3d, "WindowCreate",0 as double,0 as double,640 as double,480 as double,1 as double,result as double be aliased/mapped to something like
xWindowCreate(double,double,double,double,double) as double and then be used like
result = xWindowCreate(0,0,640,480,1) Thanks for any replies
|
|
|
Post by tsh73 on May 29, 2022 1:24:49 GMT -5
Actually it is done almost every time. You create LB wrapper and use it as ordinary function, like this (From libertybasiccom.proboards.com/thread/1824/simulate-mouse-click) result = SetCursorPos(desiredX, desiredY) ... Function SetCursorPos(X, Y) CallDLL #user32, "SetCursorPos", X As long, _ Y As long, _ SetCursorPos As long End Function
|
|
|
Post by matty47 on May 29, 2022 1:42:46 GMT -5
Thanks for the quick response. Once shown it seems so obvious!
|
|
|
Post by Rod on May 29, 2022 8:29:06 GMT -5
The LBPE covers API calls. While I see you understand the API the tutorial may cover a quirk or two calling the API from within Liberty. alycesrestaurant.com/lbpe/api.html
|
|
|
Post by matty47 on May 29, 2022 16:31:22 GMT -5
Thanks. I did purchase the API book at LuLu some time ago but it seemed to concentrate a ot on the windows API
|
|