Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I found the answer...<br> We need to install some components before creating connection string which is the main task. The following are the components that need to be installed.</p> <ol> <li><p>MYSQL connector<br> <a href="http://dev.mysql.com/downloads/connector/net/5.0.html" rel="nofollow noreferrer">http://dev.mysql.com/downloads/connector/net/5.0.html</a></p></li> <li><p>Microsoft Data Access Components (MDAC) 2.8<br> <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=6c050fe3-c795-4b7d-b037-185d0506396c&amp;displaylang=en" rel="nofollow noreferrer">http://www.microsoft.com/downloads/details.aspx?FamilyID=6c050fe3-c795-4b7d-b037-185d0506396c&amp;displaylang=en</a></p></li> </ol> <p>After a successful installation of MySQL and MySQL Connector we can move to your project. Go to Visual Studio >> Solution Explorer >> Add references and add a reference to MySQL.DATA from .net components.</p> <p>Then the following code can be included in our C# code for the connection.</p> <pre><code>public partial class _Default : System.Web.UI.Page { private string strProvider = "Data Source=localhost;Database=mydatabse;User ID=root;Password=a"; protected void Page_Load(object sender, EventArgs e) { MySqlConnection objMyCon = new MySqlConnection(strProvider); objMyCon.Open(); //Connection succeed and open.. } } </code></pre> <p>And we also need to import the following namespaces:</p> <pre><code>using System.Data.Odbc; using MySql.Data.MySqlClient; using MySql.Data.Types; </code></pre> <p>The user ID will be always “root” and password is the Password which we provided while installing MYSQL. Here many new user will struck.</p> <p>Asem Ibo.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload