none
Microsoft OLE DB Provider for ODBC Drivers error '80040e14'

    Question

  • can anyone help me with error

    My code looks like this

    Set objConn = CreateObject("ADODB.Connection")
    objConn.Open Application("Carsday_Connection")
    Set objCmd = Server.CreateObject("ADODB.Command")
    objCmd.ActiveConnection = objConn
    objCmd.CommandText = "Search_Enterprise"
    objCmd.Parameters.Append objCmd.CreateParameter("@OrderBy",adInteger,adParamInput,,orderby)
    objCmd.Parameters.Append objCmd.CreateParameter("@MfgID",adInteger,adParamInput,,MfgID)
    objCmd.Parameters.Append objCmd.CreateParameter("@Model",adVarChar,adParamInput,30,Model)
    objCmd.Parameters.Append objCmd.CreateParameter("@StartYear",adVarChar,adParamInput,4,StartYear)
    objCmd.Parameters.Append objCmd.CreateParameter("@EndYear",adVarChar,adParamInput,4,EndYear)
    objCmd.Parameters.Append objCmd.CreateParameter("@Startprice",adCurrency,adParamInput,,StartPrice)
    objCmd.Parameters.Append objCmd.CreateParameter("@Endprice",adCurrency,adParamInput,,EndPrice)
    objCmd.Parameters.Append objCmd.CreateParameter("@CategoryName",adVarChar,adParamInput,100,CategoryName)
    objCmd.Parameters.Append objCmd.CreateParameter("@Type",adInteger,adParamInput,,1)'Set this to one for Sub10k search
    objCmd.CommandType = 4
    Set objSearch = CreateObject("ADODB.RecordSet")
    objSearch.Open objCmd,,adOpenStatic
    Set objCmd = nothing
    picpath = Server.MapPath("/images/vehicles")
    Set objFS = Server.CreateObject("Scripting.FileSystemObject")
    If objSearch.EOF Then
    %>
    <table border="0" cellpadding="5" cellspacing="0" width="100%">
    <tr>
        <td ALIGN="center"><br><br>There are no vehicles matching your search criteria.<br><br><br></td>
    </tr>
    </table>
    <%
    Else
        If Request.QueryString("abpage") = "" then
            abpage = 1
        Else
            abpage = CInt(Request.QueryString("abpage"))
        End If       
    %>   


    I am getting the following error

    Microsoft OLE DB Provider for ODBC Drivers error '80040e14'

    [Microsoft][ODBC SQL Server Driver][SQL Server]Prepared statement '(@P1 int,@P2 int,@P3 varchar(30),@P4 varchar(4),@P5 varchar(4),@' expects parameter @P8, which was not supplied.

    /list.asp, line 87

    Tuesday, October 02, 2007 9:37 PM