Results 1 to 3 of 3

Thread: Command OBJECT...

  1. #1

    Thread Starter
    ^:^...ANGEL...^:^ wrack's Avatar
    Join Date
    Mar 2002
    Location
    Melbourne, AUSTRALIA
    Posts
    2,695

    Thumbs up Command OBJECT...

    I am using following code to create a connection and recordset object...It works fine...

    Now can some one shows me how to use COMMAND OBJECT of ADO to update, delete or adding a new record in database...

    VB Code:
    1. Option Explicit
    2.  
    3. Public cnnLocation As ADODB.Connection
    4. Public rsLocation_Network As ADODB.Recordset
    5.  
    6. Public strLocation_Network As String
    7.  
    8. Public strApp_Path_Network As String
    9.  
    10. Public Sub ADOLocation()
    11.     Set cnnLocation = New ADODB.Connection
    12.     Set rsLocation_Network = New ADODB.Recordset
    13.  
    14.     strConnectionLocation = "Provider=Microsoft.Jet.OLEDB.4.0;" & _
    15.                         "Data Source=" & App.Path & "\CALMS.mdb;" & _
    16.                         "Persist Security Info=False"
    17.    
    18.     cnnLocation.ConnectionString = strConnectionLocation
    19.     cnnLocation.Open strConnectionLocation
    20.    
    21.     strLocation_Network = "SELECT * FROM [Network]"
    22.     rsLocation_Network.Open strLocation_Network, cnnLocation, adOpenDynamic, adLockOptimistic    
    23. End Sub

  2. #2

    Thread Starter
    ^:^...ANGEL...^:^ wrack's Avatar
    Join Date
    Mar 2002
    Location
    Melbourne, AUSTRALIA
    Posts
    2,695

    Thumbs down hmmmm....

    Is this too hard to do...???

  3. #3
    Need-a-life Member Mc Brain's Avatar
    Join Date
    Apr 2000
    Location
    Buenos Aires, Argentina
    Posts
    6,808
    Emiliano F. Martín


    If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
    Encourage the person who helped you to keep doing it, and give him the points he deserves.


    MP3 Organizer: Freeware to logically organize all your MP3s.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width