For Programmers: Free Programming Magazines  


Home > Archive > ASP > October 2006 > Microsoft VBScript runtime (0x800A000D) Type mismatch: '[string: "









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Microsoft VBScript runtime (0x800A000D) Type mismatch: '[string: "
Snow

2006-10-30, 6:59 pm

Hello:

I have Error Type:
Microsoft VBScript runtime (0x800A000D)
Type mismatch: '[string: "2, 0"]'

The error happened at this line: if session("systemIdCount" &
arrSystems(iLoop)) > 0

The code like this:

strSystems = session("strSystems") '' Capture SystemId Array
arrSystems = split(strSystems, ",")

iLoop = 0
For iLoop = LBound(arrSystems) to UBound(arrSystems) '' Start SystemId Array
Loop
arrSystems(iLoop) = Trim(arrSystems(iLoop))
computerCount = computerCount + 1
session("systemId" & arrSystems(iLoop)) = arrSystems(iLoop) '' Define
SystemId Session

if request.querystring("newOrder") = "true" then '' Resets Session if it is
a New Order
session("systemIdCount" & arrSystems(iLoop)) = request("systemIdCount" &
arrSystems(iLoop)) '' Define SystemId Count Session
end if

if session("systemIdCount" & arrSystems(iLoop)) > 0 then '' Check if count
is grater than 0
varSysId = session("systemId" & arrSystems(iLoop))
for varItemNum = 1 to session("systemIdCount" & arrSystems(iLoop)) '
varItemNum Loop
..........

I thought that the error was that session should be int, so add cint to the
this line: if (session("systemIdCount" & arrSystems(iLoop))) > 0 However, I
got mismatch "cint" error.

What am I missing here?

Your help is highly appreciated.

Larry Bud

2006-10-30, 6:59 pm


Snow wrote:
> Hello:
>
> I have Error Type:
> Microsoft VBScript runtime (0x800A000D)
> Type mismatch: '[string: "2, 0"]'
>
> The error happened at this line: if session("systemIdCount" &
> arrSystems(iLoop)) > 0
>
> The code like this:
>
> strSystems = session("strSystems") '' Capture SystemId Array
> arrSystems = split(strSystems, ",")
>
> iLoop = 0
> For iLoop = LBound(arrSystems) to UBound(arrSystems) '' Start SystemId Array
> Loop
> arrSystems(iLoop) = Trim(arrSystems(iLoop))
> computerCount = computerCount + 1
> session("systemId" & arrSystems(iLoop)) = arrSystems(iLoop) '' Define
> SystemId Session
>
> if request.querystring("newOrder") = "true" then '' Resets Session if it is
> a New Order
> session("systemIdCount" & arrSystems(iLoop)) = request("systemIdCount" &
> arrSystems(iLoop)) '' Define SystemId Count Session
> end if
>
> if session("systemIdCount" & arrSystems(iLoop)) > 0 then '' Check if count
> is grater than 0
> varSysId = session("systemId" & arrSystems(iLoop))
> for varItemNum = 1 to session("systemIdCount" & arrSystems(iLoop)) '
> varItemNum Loop
> .........
>
> I thought that the error was that session should be int, so add cint to the
> this line: if (session("systemIdCount" & arrSystems(iLoop))) > 0 However, I
> got mismatch "cint" error.
>
> What am I missing here?


Put a response.write in giving you the session variable that you're
trying to build

response.write(systemIdCount" & arrSystems(iLoop))

This will tell you the reason for the error.

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com