recordset connect pb

Results 1 to 2 of 2

Thread: recordset connect pb

  1. #1
    thewz Guest

    Default recordset connect pb

    here is the code (as in my book)<BR><BR>function addrub(newrub2, rub2)<BR>set objRS = Server.CreateObject("ADODB.Connection")<BR>objRS.O pen "rubriques", objConn, , ,"adCmdTable"<BR><BR><BR>end function<BR>sub connect<BR>set objConn = Server.CreateObject("ADODB.Connection")<BR>objConn .ConnectionString = "DRIVER={Microsoft Access Driver (*.mdb)};" & "DBQ=" & Server.MapPath("clictout.mdb")& ""<BR>objConn.Open<BR>end sub<BR><BR>after having launch connect, i launch addrub, but i get this error message!??<BR><BR><BR>Microsoft VBScript runtime erreur &#039;800a01c2&#039; <BR><BR>Wrong number of arguments or invalid property assignment: &#039;objRS.Open&#039; <BR><BR>/clictout/tete.asp, ligne 8 <BR><BR><BR>thank you for your help!

  2. #2
    Join Date
    Dec 1969

    Default RE: recordset connect pb

    You need to create a recordset, not a connection.<BR><BR>set objRS = Server.CreateObject("ADODB.Recordset")<BR>

Posting Permissions

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