p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   Classic ASP Databases (http://p2p.wrox.com/forumdisplay.php?f=62)
-   -   JET Panic :/ what is wrong??? (http://p2p.wrox.com/showthread.php?t=8995)

Greywacke February 5th, 2004 11:32 AM

JET Panic :/ what is wrong???
 
Error Type:
Microsoft JET Database Engine (0x80040E10)
No value given for one or more required parameters.
/rpgcasino/scripts/functions.asp, line 63

Code:

With Response
    If gwPag = "0" Or gwPag = "1" Or gwPag = "5" Or gwPag = "6" Then
        .Write "var f = new Array();" & vbCrLf
        .Write "function selcountry() {" & vbCrLf
        .Write "    i = document.frm_racc.racc_country.selectedIndex;" & vbCrLf
        .Write "    document.images['flag'].src = 'iface/flags/' + i + '.gif';" & vbCrLf
        .Write "    loadstates(i);" & vbCrLf
        .Write "}" & vbCrLf
        .Write "var p = new Array();" & vbCrLf
        .Write "p[0] = '<-- No states/provinces available -->';" & vbCrLf
        Set gwRS = Server.CreateObject("ADODB.Recordset")
        Set gwRS1 = Server.CreateObject("ADODB.Recordset")
        SQLStr = "SELECT * FROM countries ORDER BY str_name ASC"
        gwRS.Open SQLStr, gwConn, adOpenDynamic, adLockOptimistic, adCmdText
        i = 1
        Do While Not gwRS.EOF
            .Write "p[" & i & "] = '"
            cid = gwRS("lng_id")
            SQLStr = "SELECT str_name FROM states WHERE lng_countryid = " & cid & " ORDER BY str_name ASC"
            gwRS1.Open SQLStr, gwConn, adOpenDynamic, adLockOptimistic, adCmdText ' line 63
            Do While Not gwRS1.EOF
                .Write Replace(gwRS1("str_name"),"'","\'") & ", "
                gwRS1.MoveNext
            Loop
            .Write "';" & vbCrLf
            gwRS1.Close
            i = i + 1
            gwRS.MoveNext
        Loop
        gwRS.Close
    ' more If statements for the other cases of gwpag
    End If
End With

basically what the hell is up with that? i am kinda starting to panic here... the adodb constants library is included in the global.asa, and the connection is set to Application("gwConn") at start of page... other scripts work perfectly, it's just this one which implicates that gwRS("lng_id") is returning a blank string, while in actual fact it is returning the country id (long number)???

any swift help to resolve this issue will be greatly appreciated...

Sincerely,
Pierre du Toit.

Imar February 5th, 2004 12:43 PM

Hi there,

Take a look at this FAQ:

http://www.adopenstatic.com/faq/80040e10.asp

Cheers,

Imar


---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.


All times are GMT -4. The time now is 04:12 PM.

Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.