Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / passing strings to a dll

Author
Message
waffle
16
Years of Service
User Offline
Joined: 9th Sep 2002
Location: Western USA
Posted: 6th Oct 2002 04:33
DBPro does not seem to like passing a string to a DLL...
is this true or did i miss something?
i remember the old db113 did not like strings with special characters in it (tab,crlf and so on). So, could this be a problem with the null terminated sring expectations of c ?
waffle
16
Years of Service
User Offline
Joined: 9th Sep 2002
Location: Western USA
Posted: 6th Oct 2002 20:28
i can't figure out how to remove this topic, so i'll just answer my own question...

i tested my DLL file from a C program and it works, but it crashed with DB. The problem (not a bug) is that C can have functions that accept any type of parameter. Since the type of parameter was unknown at the time of the call, DB could not locate a matching function. The solution, of course, was for me to "fix" the DLL to handle only one type of variable instead of any type. Sorry if i confused anybody with my simple question

Login to post a reply

Server time is: 2019-08-26 08:22:31
Your offset time is: 2019-08-26 08:22:31