Please explain this ADO-related code for me

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • firozfasilan
    New Member
    • Feb 2007
    • 42

    Please explain this ADO-related code for me

    please give me the explanation of these code
    i am a trainee programmer.
    Code:
    Private Sub Command2_Click()
    Dim ADOcommand As New ADODB.Command
    Dim ADOconnection As New ADODB.Connection
    Dim RSSales As New ADODB.Recordset
    
    Set ADOconnection = CreateObject("ADODB.Connection")
    ADOconnection.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & App.Path & "\NWIND.MDB; Persist Security Info= False"
    Set ADOcommand.ActiveConnection = ADOconnection
    ADOcommand.Prepared = False
    ADOcommand.CommandText = "Invoices"
    ADOcommand.CommandType = adCmdStoredProc
    Set RSSales = ADOcommand.Execute()
    Last edited by Killer42; Feb 12 '07, 09:17 AM. Reason: Please use CODE tags
  • Esmael
    New Member
    • Feb 2007
    • 58

    #2
    Hi..

    It olny execute what is in the Store Procedure...

    Comment

    Working...