This is one of the pre requisite in order to connect and use MySQL database with ASP.NET
First step is to download and install MySQL ODBC Connector
Once you installed MySQL odbc connector -> Open ODBC Data Source administrator simply by typing ODBC in start menu. You’ll find the following dialog box

odbc-connector-mysql-asp.net
Under User DSN – click on Add
If you had successfully installed the MySQL ODBC connector you’ll find “MySQL ODBC 5.1 Driver” select it and click finish

mysql-driver-installed-for-odbc-visual-studio
Now the follwing dialog box will appear. Use a data source name -> Use standard name -> you should remember this name for giving connection string etc.
The TCP/IP server is “Localhost”
Port no is 3306
user – root
pwd – nil

mysql-connection-parameters-odbc
Now click on test connection -> if everything goes successfull then you’ll get connection success dialog as in the following.

test-connection-mysql-odbc-visual-studio-asp.net
Final Steps
Then expand the details
Under connections click the check boxes on
Under cursor/results click the check boxes on
|
|
don't cache results of forward only cursors |
|
|
force use of forward only cursors |
Now you are ready to use MySQL database with ASP.NET use this tutorial Using MySQL with ASP.NET