Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Hello,

 

I am starting to use VB.net now over vb6

 

to open DB in vb6 I do:

 

 

myConnection.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & VB6.GetPath & "\Data.mdb;Mode=ReadWrite|Share Deny None;Persist Security Info=False"

myConnection.Open()

 

Dim myrecordset As ADODB.Recordset

myrecordset = New ADODB.Recordset

 

myrecordset.Open("Select * from test", myConnection, ADODB.CursorTypeEnum.adOpenDynamic, ADODB.LockTypeEnum.adLockOptimistic)

 

 

myrecordset.Fields("name").Value = "TESTNEW"

 

myrecordset.Update()

 

 

When I migrated to Vb.Net this still worked, I think it is still using ADO

 

Could someone show me how to do the above code with ado.net?

 

 

Also, is there any reason why I can't just stay with ADO in VB.NET?

 

 

Thanks

 

Rhys

Posted

Ok Cool, Thanks for that, not sure if I'll go .NET just yet

 

Does anyone know if using an ODBC driver is just as stable as Direct? (Using Mysql or Postgresql)

 

Thanks

 

:)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...