Re: LibFunc from VB

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
rullbandspelare
Pro Scripter
Posts: 149
Joined: Tue Mar 23, 2004 9:11 pm

Re: LibFunc from VB

Post by rullbandspelare » Wed Jan 23, 2008 9:06 pm

In responce to my question regarding a DLL that requires record data type.
When you pass values to DLLs what you actually pass are references to memory locations. Macro Scheduler can only talk to DLLs that accept integers and/or char pointers (strings). Your function requires a custom type - a record. It's VB specific.
_________________
Regards,
Marcus Tettmar
Blog: http://mjtnet.com/blog/
Please do not email or PM me with private support requests - post questions to the forum so that everyone benefits. For fast, guaranteed private support please send email via our web site.
So, what are the best workaround for this? Should i just try to compile the DLL function whithin Visual Basic and feed the result to a file?
Is there any plans for enhancing MacroScheduler to handle this?

Thanks!
/tomas

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Wed Jan 23, 2008 9:19 pm

It's not a question of enhancing Macro Scheduler. Your DLL is probably only compatible with VB.

Macro Scheduler can only be compatible with standard DLLs created with the stdcall calling convention. Basic string and integer types are required.

The workaround would be to recompile your DLL to make sure it is using the standard (stdcall) calling convention and instead of a record type specify each of the strings separately in the parameter list as individual parameters.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts