How to update VB6 database code to VB.NET?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Hamadi
    New Member
    • Jan 2011
    • 1

    How to update VB6 database code to VB.NET?

    i need to upgrade system from vb6 to vb.net
    but there was a condition for the database that i cant convert it to vb.net.

    Code:
            
    Set Data2.Recordset = Db_Profile.OpenRecordset("Select * from BatchTable where datecreate = datevalue('" & Data1.Recordset.Fields("DocDate") & "') and RecCueNo = '" & Data1.Recordset.Fields("RecCueNo") & "'")
    The Data1.Recordset .Fields1 is from database1.
    The "DocDate" is a fields in database1.
    Db_Profile is database2.

    Anyone have the solution?
    Last edited by Niheel; Jan 27 '11, 03:15 PM.
  • Patrick M
    New Member
    • Jan 2011
    • 8

    #2
    Take a look at ADO.NET for VB. That's the preferred method when using .NET.

    Comment

    Working...