Problem with my DB Connection... HELP!!!

  • Thread starter Thread starter simf1
  • Start date Start date
S

simf1

I'm Working with VB.net and i Use this connection function (see code
below). It's working perfecly, but sometime it's to long before to
have a result. Please help to optimise my code.
Best regard!
SimF1

'OpenConnection CODE(start)============

Public Sub OpenConnexion()

bdConnection = New ADODB.Connection
With bdConnection
.ConnectionString = "DRIVER={MySQL ODBC 3.51
Driver};SERVER=sqlc0b.megasqlservers.com;DATABASE=myDBNamse;UID=userId;PWD=pswd;"

.CursorLocation = ADODB.CursorLocationEnum.adUseClient
.ConnectionTimeout = 30
On Error GoTo err_Renamed
.Open()
End With

err_Renamed:
Exit Sub[/QUOTE]

'OpenConnection CODE(end)============[/QUOTE]
 
SimF,

I would ask this my SQL question as I was you in the newsgroup

Adonet
news://msnews.microsoft.com/microsoft.public.dotnet.framework.adonet

Web interface:
http://communities2.microsoft.com/c.../?dg=microsoft.public.dotnet.framework.adonet

I did already a search on your question in this newsgroup.
Probably you find in that even the answer faster.

http://groups-beta.google.com/group...tion+mysql&qt_g=1&searchnow=Search+this+group

Be aware that you are now using ADODB (ADO) what is not ADONET.

I hope this helps

Cor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top