Welcome to WebmasterWorld Guest from 54.166.33.25

Forum Moderators: buckworks

storefront 5.0 VB Script error

   
3:22 pm on Mar 24, 2006 (gmt 0)

5+ Year Member



I've got this program working perfectly except for one error. When a product search expands to more than one page I get this error when going to "next page"

Microsoft VBScript runtime error '800a000d'

Type mismatch: '[string: ""]'

/search_results.asp, line 63

Does anyone have any idea of what I should look for in the VB script?
Here is a subsection of the area involved:

sALLSUB = Request.item("txtsearchParamCat")
iLevel = Request.item("iLevel")
if ilevel = 2 and sALLSUB = "ALL" then
sSubCat = Request.item("subcat")
end if
' Requests the variables depending on how the page is entered
If txtFromSearch = "fromSearch" Then
txtsearchParamTxt= trim(Replace(Replace(Request.Form("txtsearchParamTxt"), "'", "''"), "*", ""))
txtsearchParamType= trim(Request.Form("txtsearchParamType"))
if Ilevel = 2 and sALLSUB = "ALL" then
txtsearchParamCat= sSubCat
Ilevel = 1
else
txtsearchParamCat= trim(Request.QueryString("txtsearchParamCat"))
end if
txtsearchParamMan= trim(Request.Form("txtsearchParamMan"))
txtsearchParamVen= trim(Request.Form("txtsearchParamVen"))
txtDateAddedStart= MakeUSDate(trim(Request.Form("txtDateAddedStart")))
txtDateAddedEnd = MakeUSDate(trim(Request.Form("txtDateAddedEnd")))
txtPriceStart= trim(Request.Form("txtPriceStart"))
txtPriceEnd = trim(Request.Form("txtPriceEnd"))
txtSale= trim(Request.Form("txtSale"))
Else
txtsearchParamTxt= trim(Replace(Replace(Request.QueryString("txtsearchParamTxt"), "'", "''"), "*", ""))
txtsearchParamType= trim(Request.QueryString("txtsearchParamType"))
if Ilevel = 2 and sALLSUB = "ALL" then
txtsearchParamCat= sSubCat
Ilevel = 1
else
txtsearchParamCat= trim(Request.QueryString("txtsearchParamCat"))
end if

1:19 pm on Mar 26, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Can you paste line 63?
10:10 pm on Mar 27, 2006 (gmt 0)

10+ Year Member



Are you deploying storefront5.0 from Lagarde?
5:29 pm on Mar 28, 2006 (gmt 0)

5+ Year Member



I found a work-around. I edited the search_results asp script to include 100 items per page so that changing pages wasn't necessary - I just scroll instead. The problem is in the "call" parameters for search_results.asp. Here's what it looks like for page 1:

"http://mywebsite/search_results.asp?txtsearchParamTxt=&txtsearchParamCat=ALL &txtsearchParamType=ALL&iLevel=1&txtsearchParamMan=ALL&txtsearchParamVen=ALL &txtFromSearch=fromSearch&btnSearch.x=13&btnSearch.y=13"

When trying to view page 2 the "ALL" parameters are missing.Apparantly the search_results.asp needs values and therefore would not load. Initially, search_results.asp is set to only show 10 items, I increased to to 100 thereby avoiding the problem.

BTW, this is Lagarde's storefront 5 (seems like some kind of bug to me)

[edited by: jatar_k at 5:13 pm (utc) on Mar. 30, 2006]
[edit reason] added spaces to url to stop sidescroll [/edit]

10:17 pm on Mar 28, 2006 (gmt 0)

10+ Year Member



I used 5 for a while. I don't recall getting that error out of the box. I would back out each mod made one by one for that page until it works. It has been a few years though. Why aren't you on 6 if just starting?

Take care,

Brian

8:14 pm on Mar 29, 2006 (gmt 0)

10+ Year Member



As an afterthought I would rename search_results.asp to something else. Then from your install files grab the "stock" search_results.asp and test with that. If it works then you know it is something that was modded on search_results.asp and I would revert back to my last posts advise.

HTH,

Brian

5:10 pm on Mar 30, 2006 (gmt 0)

5+ Year Member



Brian, thanks for the replies. I tried your idea and the same problem occurs with the native search_results. The error is obviously a vbscript error. I'm only a novice at deciphering the program so I'm just going to leave it by allowing a large number of products per page. It works fine this way and franky its easier to scroll through one page than navigate through many.
 

Featured Threads

My Threads

Hot Threads This Week

Hot Threads This Month