Migrating to ASP.net from ASP Having trouble with rs.open

ghornet
ghornet used Ask the Experts™
on
I am migrating all of my asp pages to aspx everything is going pretty well except for this little snag here

rs.Open(sTable, cn, 2,2) is giving me an error

Exception Details: System.Runtime.InteropServices.COMException: The request for procedure 'Productivity' failed because 'Productivity' is a table object.


the code block it is in is as follows

sTable = "[Productivity]"
cn = CreateObject("ADODB.Connection")
cn.Open(strConn)
      
'=====Form=======
If Len(Request.QueryString("save")) > 0 Then
       rs = Server.CreateObject("ADODB.Recordset")
      rs.Open(sTable, cn,2,2)
      rs.addnew
                  rs("MechanicID") = MchID
                  rs("Score") = Score
                  rs("ScoreRight") = scoreright
                  rs("Per") = per
                  rs("Date") = myDate
                  rs("LocationID") = SID
                  rs("UserID") = UID
                  rs.Update      
rs.close()      

that is pretty much it... any ideas?

D--
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Top Expert 2006
Commented:
Try

rs.Open(sTable, cn,1,3,2)

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial