Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.
Hi all, please see this major site announcement: https://www.boards.ie/discussion/2058427594/boards-ie-2026

C#/C++ to mySQL

  • 07-01-2008 06:34PM
    #1
    Registered Users, Registered Users 2 Posts: 1,991 ✭✭✭


    I've a site up and running and was interested in developing an app in c#(preferred) or c++ that uses this existing DB from the site which is a mySQL DB, is it possible??


Comments

  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    Yes.


  • Registered Users, Registered Users 2 Posts: 1,991 ✭✭✭Ziycon


    Yes.
    Thanks, thats all i need to know, appreciated!:D


  • Registered Users, Registered Users 2 Posts: 1,991 ✭✭✭Ziycon


    Ziycon wrote: »
    Thanks, thats all i need to know, appreciated!:D
    Ok i lied, I'm back, trying to follow this tutorial(http://www.functionx.com/mysqlnet/vcnet/Lesson02.htm), is this right what i have so far? Keep in mind its about a year since I've used C++!
    using namespace std;
    
    int main()
    {
    	return 0;
    }
    
    private: System::Void btnConnect_Click(System::Object *  sender, System::EventArgs *  e)
    {			
    	 MySqlConnection *conSQL = new MySqlConnection(S"Server=11.11.111.111;"
    			                                       S"Persist Security Info=no;"
    			                                       S"User Name='username';"
    												   S"Password='password'");
    }
    


  • Registered Users, Registered Users 2 Posts: 981 ✭✭✭fasty


    That code is just taken straight from the tutorial with additional connection details.

    Why not call the Open() function of conSQL and see if it throws an exception, or print info about the connection state?

    Here are some docs on it...

    The examples are in VB and C# as opposed to managed C++ but you'll get the general idea.

    You can also use ADO.net to connect to MYSql databases btw.


  • Registered Users, Registered Users 2 Posts: 610 ✭✭✭nialo


    Ziycon, you still having issues with this? drop me a mail on netsoc if you are..


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 7,468 ✭✭✭Evil Phil


    Folks,

    It clearly states that asking for private messges is against the forum rules. It breaks the flow of the thread. Please refrain from doing so Nialo.

    E.P.


  • Registered Users, Registered Users 2 Posts: 610 ✭✭✭nialo


    apologies!


Advertisement