Author Topic: dynamic libraries  (Read 4748 times)

roglio

  • Guest
dynamic libraries
« on: November 04, 2013, 08:49:32 pm »
Hi guys!

I am new using code::blocks, but not new doing programming. I have some problems understanding the proper way to link/dinamically libraries, and so I need someone who can point me out the right direction!

Im trying to connect to a MySql database using SqlApi++ Library. So I follow this tutorial: http://cbsecsnip.in/tutorial/how-to-connect-MySQL-database-with-CPP/how-to-connect-MySQL-database-with-CPP.php

I can build my project correctly. However when I try to run my .exe file, it crashes! the cmd window pops up and then a warning message window pops up saying that the myAppName.exe has stopped working. The problem is (I beleived) the file libsqlapid.dll which I have copied into my project's debug folder under the bin folder (as the tutorial suggests).

So my question is, what am I doing wrong? Or where can i find a good source with examples than i can read and follow to work out the exampel. I have been reading the info her in code::blocks website and in sqlapi++ website but i dont find anything.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7602
    • My Best Post
Re: dynamic libraries
« Reply #1 on: November 04, 2013, 11:02:41 pm »
Read the rules; and, find a programming help site for your Compiler!


http://forums.codeblocks.org/index.php/topic,9996.0.html

Quote
1. This is NOT a general programming board. "How do I write a program that....", "Can anybody teach me how to", "I have this homework", "My program doesn't run and I don't have the slightest idea of why because I'm a C++ newcomer", "What is a compiler", "What does gcc do" is the kind of questions that is FORBIDDEN to ask.

2. Compiler/Linker errors are NOT Code::Blocks errors. Usually, C++ newcomers tend to confuse the Editor/IDE (Code::Blocks) with the Compiler (MINGW / GCC). You may see some errors in the compiler output because you missed to do something right in your code. But that's not Code::Blocks troubleshooting, that's C++ troubleshooting and does not belong in here. If your program doesn't compile, READ THE C++ MANUAL.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org