Hello at all,
i can't load a library for example ..
Ret = OpenLibrary(#PB_Any, "libmysql.dll")
Debug Ret
Return 0
the libmysql.dll is in the same directory of the program and 64 bit version as
purebasic and windows 10.
The libmysql.dll version is 6.1 ..
what is the problem
thanks
Mysql with libmysql
Re: Mysql with libmysql
check compiler options and there the compile/run tab
Whenever relative paths fail, you should use an absolute path to make sure the location is not the problem (or use PB commands to check the local path at execution time with GetCurrentDirectory() since it depends on your compiler settings). It could be an architecture problem (32/64 bit) but you said you checked that. Anyway i wonder why you try to load mysql like that, have you looked into help and "database" and does the "database.pb" example work for you?
Whenever relative paths fail, you should use an absolute path to make sure the location is not the problem (or use PB commands to check the local path at execution time with GetCurrentDirectory() since it depends on your compiler settings). It could be an architecture problem (32/64 bit) but you said you checked that. Anyway i wonder why you try to load mysql like that, have you looked into help and "database" and does the "database.pb" example work for you?
Last edited by Bitblazer on Fri Mar 02, 2018 10:20 am, edited 2 times in total.
Re: Mysql with libmysql
Thanks for answer ,
yes i tryed with absolute path but nothing to do ...
Option compiler is ok ...
thanks for your help
yes i tryed with absolute path but nothing to do ...
Option compiler is ok ...
thanks for your help
Re: Mysql with libmysql
Yes, i tryed it
but nothing to do ...
I working with windows 10 Home, and the error is on open library ....
I believe is a bug..
thanks
Maurizio
but nothing to do ...
I working with windows 10 Home, and the error is on open library ....
I believe is a bug..
thanks
Maurizio
Re: Mysql with libmysql
Hi,
the lib is there opened. So it is not a problem of PB.
Do you use PB x64? Is the dll for x64?
the lib is there opened. So it is not a problem of PB.
Do you use PB x64? Is the dll for x64?
Re: Mysql with libmysql
Sorry ,
thanks for the help
but the openlibrary return 0 and documentation tell me
that is an error.
thank
Maurizio
thanks for the help
but the openlibrary return 0 and documentation tell me
that is an error.
thank
Maurizio
Re: Mysql with libmysql
0 is an error.
That's why I asked for your PB version and your dll version.
You can not open a 23 bit dll with a x64 PB and vice versa.
That's why I asked for your PB version and your dll version.
You can not open a 23 bit dll with a x64 PB and vice versa.
Re: Mysql with libmysql
Sorry ,
i founded error my libmysql.dll was 32 bit in directory exe,
in windows the lib was x64 ...
Argh ..
Exscuse me for the error, thank for help ....
Purebasic is Great...
bye
Maurizio
i founded error my libmysql.dll was 32 bit in directory exe,
in windows the lib was x64 ...
Argh ..
Exscuse me for the error, thank for help ....
Purebasic is Great...
bye
Maurizio
Re: Mysql with libmysql
Dynamic-Link Library Search Ordermauriegio wrote:Sorry ,
i founded error my libmysql.dll was 32 bit in directory exe,
in windows the lib was x64 ...
https://msdn.microsoft.com/en-us/librar ... s.85).aspx
YesPurebasic is Great...
