re; pt. 1. No i didn't. I am a noob but not that much of a noob : ) I've set that up as per"This is what i got form my host(will change security sensitive stuff):
Your MySQL database settings Server Name: mysql-913 Server IP Address: 243.131.32.34 Database Name: zebradat Database Username: zebradatadmin Database Password: 3vex491"
re; pt.2. Pass it as a param. in the assembly of/ or the page itself on which data is supposed to be displayed/pulled in? or? And is this C#?.. since I'm using VB. Could you please copy and paste the whole string from somewhere.. changing/removing the security
sensitive stuff.. obviously ;)
re; pt.3. you mean setting customErrors
mode="Off" ? I've done that some time ago...
pt2: Well yes, I am assuming you know how to work with ADO.NET right? Do you know how to use SqlConnection? I was assuming so and just providing you with the fill in the blanks between MS Sql classes and MySql classes, if you are not very familier with ADO.NET
Google up some simple samples on how to connection to a database through asp.net using MS SQL and when you understand that you will see the MySql solution easily. Sorry about C#, yes if I knew VB I would write that for you, but you are gonna do the translation
yourself.
As for the code, I already gave it to you several times :) but I guess you are misunderstanding it as a connection string to be put in Web.Config
here it is again, remember this is your C# Code
MySqlConnection
connection =
new
MySqlConnection ("database=zebradat;server=243.131.32.34;user id=zebradatadmin;Password=3vex491;");
connection.Open(); // your connection should open now.
pt3: yes that is correct, but the error that your site is giving you indicates that it is not put to off, double check it.
Regards.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
My Blog If you get the answer to your question, please mark it as the answer.
No, I'm not familiar w ado.net I'm afraid : ( Will research...
As for the customErrors
mode="Off" .. it is off.. but I know what you mean.
It was showing me different(more specific) error messages before it's just that it displyed this one after i entered &uploaded the above (<add
name="ConnectionString"
MySqlConnection
connection =
new
MySqlConnection("databas.........) as the connection string.. LOL
Thank you so much for all your help ralph! Will let you know how I get on...
I've been playing around. Discovering new things re; ADO.net.. still fuzzy but getting there..
This is the error I've been getting:
Server Error in '/' Application.
Configuration Error
Description:
An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: Could not load file or assembly 'MySql.Data, Version=5.1.5.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' or one of its dependencies. The system cannot find the file specified.
Source Error:
Line 27: <compilation debug="true" strict="false" explicit="true"> Line 28: <assemblies> Line 29: <add assembly="MySql.Data, Version=5.1.5.0, Culture=neutral, PublicKeyToken=C5687FC88969C44D"/></assemblies></compilation> Line 30: <pages> Line 31: <namespaces>
Assembly Load Trace: The following information can be helpful to determine why the assembly 'MySql.Data, Version=5.1.5.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' could not be loaded.
WRN: Assembly binding logging is turned OFF. To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1. Note: There is some performance penalty associated with assembly bind failure logging. To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433
Is this something to do with MySql .net connector or??
Graphicreep
0 Points
16 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 15, 2008 11:24 AM|LINK
Thnx for the prompt reply.
re; pt. 1. No i didn't. I am a noob but not that much of a noob : ) I've set that up as per"This is what i got form my host(will change security sensitive stuff):
Your MySQL database settings
Server Name: mysql-913
Server IP Address: 243.131.32.34
Database Name: zebradat
Database Username: zebradatadmin
Database Password: 3vex491"
re; pt.2. Pass it as a param. in the assembly of/ or the page itself on which data is supposed to be displayed/pulled in? or? And is this C#?.. since I'm using VB. Could you please copy and paste the whole string from somewhere.. changing/removing the security sensitive stuff.. obviously ;)
re; pt.3. you mean setting customErrors mode="Off" ? I've done that some time ago...
Thank you ralph
ralph.varjab...
Participant
1108 Points
207 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 15, 2008 11:44 AM|LINK
pt2: Well yes, I am assuming you know how to work with ADO.NET right? Do you know how to use SqlConnection? I was assuming so and just providing you with the fill in the blanks between MS Sql classes and MySql classes, if you are not very familier with ADO.NET Google up some simple samples on how to connection to a database through asp.net using MS SQL and when you understand that you will see the MySql solution easily. Sorry about C#, yes if I knew VB I would write that for you, but you are gonna do the translation yourself.
As for the code, I already gave it to you several times :) but I guess you are misunderstanding it as a connection string to be put in Web.Config
here it is again, remember this is your C# Code
MySqlConnection connection = new MySqlConnection ("database=zebradat;server=243.131.32.34;user id=zebradatadmin;Password=3vex491;");
connection.Open(); // your connection should open now.
pt3: yes that is correct, but the error that your site is giving you indicates that it is not put to off, double check it.
Regards.
My Blog
If you get the answer to your question, please mark it as the answer.
Graphicreep
0 Points
16 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 15, 2008 12:51 PM|LINK
No, I'm not familiar w ado.net I'm afraid : ( Will research...
As for the customErrors mode="Off" .. it is off.. but I know what you mean. It was showing me different(more specific) error messages before it's just that it displyed this one after i entered &uploaded the above (<add name="ConnectionString" MySqlConnection connection = new MySqlConnection("databas.........) as the connection string.. LOL
Thank you so much for all your help ralph! Will let you know how I get on...
ralph.varjab...
Participant
1108 Points
207 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 15, 2008 02:58 PM|LINK
Sure, you can find a lot of resources on the net for this and later on if you need further help, do not hesitate.
My Blog
If you get the answer to your question, please mark it as the answer.
ralph.varjab...
Participant
1108 Points
207 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 15, 2008 02:59 PM|LINK
Sure, you can find a lot of resources on the net for this as the topic is way too big for a post.
And later on if you need further help, do not hesitate.
My Blog
If you get the answer to your question, please mark it as the answer.
Graphicreep
0 Points
16 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 15, 2008 04:17 PM|LINK
I understand ralph. Thank you for all the help so far
Graphicreep
0 Points
16 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 18, 2008 04:16 PM|LINK
Hi Ralph,
Hope you well.
I've been playing around. Discovering new things re; ADO.net.. still fuzzy but getting there..
This is the error I've been getting:
Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.Parser Error Message: Could not load file or assembly 'MySql.Data, Version=5.1.5.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' or one of its dependencies. The system cannot find the file specified.
Source Error:
Source File: e:\domains\m\mangonet.ourwebnet.com\user\htdocs\web.config Line: 29
Assembly Load Trace: The following information can be helpful to determine why the assembly 'MySql.Data, Version=5.1.5.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' could not be loaded.
Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433
Is this something to do with MySql .net connector or??
ralph.varjab...
Participant
1108 Points
207 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 18, 2008 10:24 PM|LINK
Is this error from the website on the same computer that you are developing the application? I mean did you deploy it on another machine?
Try removing the reference to MySql.Data.dll in your project and readding it. From the way I see it, this is just a VS mess up.
Let me know.
My Blog
If you get the answer to your question, please mark it as the answer.
Graphicreep
0 Points
16 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 21, 2008 08:28 AM|LINK
It's the error on the remote server(host).. not local.
Will try removing the MySql.Data.dll reference and uploading.. Thanks
ralph.varjab...
Participant
1108 Points
207 Posts
Re: Can't connect to the MySQL database online. Please help!
Apr 21, 2008 09:39 AM|LINK
Make sure you have the MySql.Data.dll on the server as well (in the bin directory) or else it will give you the above error.
My Blog
If you get the answer to your question, please mark it as the answer.