Why this Recordset error help me please?

Results 1 to 2 of 2

Thread: Why this Recordset error help me please?

  1. #1
    Join Date
    Dec 1969

    Default Why this Recordset error help me please?

    I am using this function and I am getting the below error, why am i getting this?<BR><BR><BR>Function GetCatID(strName)<BR> Dim SQL <BR> <BR> <BR> SQL = " SELECT * FROM Category Where Category = &#039" & gCategory & "&#039 "<BR> Set grsTemp = CreateObject("ADODB.Recordset")<BR> Response.Write SQL <BR> <BR> grsTemp.Open SQL, gConn, adOpenForwardOnly, adLockReadOnly, adCmdText<BR> GetCatID = grsTemp("CatID")<BR> grsTemp.Close<BR> Set grsTemp = Nothing<BR><BR>End Function<BR><BR>ADODB.Recordset error &#039 800a0bb9&#039 <BR><BR>The application is using arguments that are of the wrong type, are out of acceptable range, or are in conflict with one another. <BR><BR>/temp/admin/edit.asp, line 255 <BR><BR><BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Why this Recordset error help me please?

    Could be many things...<BR><BR>What is gconn = ? This should be a connection object pointing to a dsn or db connection. Otherwise, replace this with "DSN=dsnname" or a pointer to the db.<BR><BR>Do you have a reference to ADOVBS.inc in the file somewhere? To use the asOpenForwardOnly..., you need to have a reference to this file to define the constants.<BR><BR>I usually do not have the adCmdText on my queries.<BR><BR>HTH<BR><BR>Jerry

Posting Permissions

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