Ask a Question related to ASP, Design and Development.
-
Rahul Bakshi #1
Microsoft VBScript runtime error '800a01c9'
Hi
I am getting this error which is frustrating me a lot
Microsoft VBScript runtime error '800a01c9'
This key is already associated with an element of this collection
/process.asp, line 362
the following is the code snippet:
Sub AddItemToCart(iItemID, iItemCount)
aParameters = GetItemParameters(iItemID)
If dictCart.Exists(iItemID) Then
If CInt(aParameters(6)) > CInt(dictCart(iItemID)) then
dictCart(iItemID) = dictCart(iItemID) + iItemCount
Response.Write "<font face=Verdana color=#c8c8c8 size=2>" &
iItemCount & " of item # " & iItemID & " have been added to your
cart.<BR><BR></font>" & vbCrLf
Else
Response.Write "<font face=Verdana color=#c8c8c8 size=2>" & "There
is no more stock available to add<BR><BR></font>" & vbCrLf
End If
Else
If CInt(aParameters(6)) > CInt(dictCart(iItemID)) then
dictCart.Add iItemID, iItemCount >>>>>>>> line 362 <<<<<<<<<<<<<
Response.Write "<font face=Verdana color=#c8c8c8 size=2>" &
iItemCount & " of item # " & iItemID & " have been added to your
cart.<BR><BR></font>" & vbCrLf
Else
Response.Write "<font face=Verdana color=#c8c8c8 size=2>" & "There
is no more stock available to add<BR><BR></font>" & vbCrLf
End If
End If
End Sub
Please suggest me if you can find some error
regards
Rahul
Rahul Bakshi Guest
-
Microsoft VBScript runtime error '800a01ad'
I get the following error message when trying to create an instance of a DLL on a Windows 2003 Server machine from an ASP page: Microsoft VBScript... -
Error : Microsoft VBScript runtime (0x800A000D)
Hi, I get an error Type mismatch: 'LBound' when I try to submit my form, which saves the form data to database. There is not much of a help... -
Microsoft VBScript runtime error '800a000d' ??
can someone help me out i keep getting this error ? Microsoft VBScript runtime error '800a000d' Type mismatch: 'IsBlank' /dating/admin.asp,... -
Microsoft VBScript runtime error '800a01fb'
Hello All, I started getting the following error for some unknow reason and can not figure out why. Here are the errors I am getting: An... -
Microsoft VBScript runtime error '800a0046'
hello all, i have a permission issue. my script works fine on my windows2000 server development box, however when i move it to my windows2003... -
Ray at #2
Re: Microsoft VBScript runtime error '800a01c9'
That means that you're trying to add something into your dictionary object
with the same key as another item that already exists. For example:
This will cause that error:
objYourDictionaryObject.Add "key1", "Bird"
objYourDictionaryObject.Add "key1", "Cat"
This will not cause an error:
objYourDictionaryObject.Add "key1", "Bird"
objYourDictionaryObject.Add "key2", "Cat"
See how the keys are different? They must be.
"Rahul Bakshi" <rbakshi@usc.edu> wrote in message
news:f17101a7.0309272045.330b2518@posting.google.c om...> Hi
>
> I am getting this error which is frustrating me a lot
>
> Microsoft VBScript runtime error '800a01c9'
>
> This key is already associated with an element of this collection
>
> /process.asp, line 362
>
> the following is the code snippet:
>
>>
> Sub AddItemToCart(iItemID, iItemCount)
> aParameters = GetItemParameters(iItemID)
>
> If dictCart.Exists(iItemID) Then
>
> If CInt(aParameters(6)) > CInt(dictCart(iItemID)) then
> dictCart(iItemID) = dictCart(iItemID) + iItemCount
> Response.Write "<font face=Verdana color=#c8c8c8 size=2>" &
> iItemCount & " of item # " & iItemID & " have been added to your
> cart.<BR><BR></font>" & vbCrLf
> Else
> Response.Write "<font face=Verdana color=#c8c8c8 size=2>" & "There
> is no more stock available to add<BR><BR></font>" & vbCrLf
> End If
>
> Else
> If CInt(aParameters(6)) > CInt(dictCart(iItemID)) then
> dictCart.Add iItemID, iItemCount >>>>>>>> line 362 <<<<<<<<<<<<<
> Response.Write "<font face=Verdana color=#c8c8c8 size=2>" &
> iItemCount & " of item # " & iItemID & " have been added to your
> cart.<BR><BR></font>" & vbCrLf
> Else
> Response.Write "<font face=Verdana color=#c8c8c8 size=2>" & "There
> is no more stock available to add<BR><BR></font>" & vbCrLf
> End If
>
> End If
>
> End Sub
>
>
> Please suggest me if you can find some error
>
>
>
> regards
>
> Rahul
Ray at Guest
-
Rahul Bakshi #3
Re: Microsoft VBScript runtime error '800a01c9'
Hi
I know the cause of the error
However i do not understand how the dictionary already has those keys
as this is the first item I am trying to add.
thanks for the quick response
regards
Rahul
*** Sent via Developersdex [url]http://www.developersdex.com[/url] ***
Don't just participate in USENET...get rewarded for it!
Rahul Bakshi Guest
-
Ray at #4
Re: Microsoft VBScript runtime error '800a01c9'
Throw in some response.writes and watch the keys.
Ray at home
"Rahul Bakshi" <rbakshi@usc.edu> wrote in message
news:%23pXsdHYhDHA.1272@TK2MSFTNGP09.phx.gbl...> Hi
>
> I know the cause of the error
>
> However i do not understand how the dictionary already has those keys
> as this is the first item I am trying to add.
>
> thanks for the quick response
>
> regards
> Rahul
>
> *** Sent via Developersdex [url]http://www.developersdex.com[/url] ***
> Don't just participate in USENET...get rewarded for it!
Ray at Guest



Reply With Quote

