Solved

ASP.Net: Session Object: Item has already been added. Key in dictionary: 'MyKey' Key being added: 'MyKey'

Posted on 2009-04-08
2
914 Views
Last Modified: 2012-06-27
This is bizarre.

I've been doing ASP for over 10 years and I've never seen this before.   The below line of code is failing.  Why?  I've re-assigned values to collection keys dozens of times.  Why would this start complaining now?

The error message:

 Item has already been added. Key in dictionary: 'MyKey' Key being added: 'MyKey'
Session["MyKey"] = "some string"

Open in new window

0
Comment
Question by:ZuZuPetals
2 Comments
 
LVL 16

Assisted Solution

by:sunithnair
sunithnair earned 300 total points
ID: 24098828
0
 
LVL 2

Accepted Solution

by:
ZuZuPetals earned 0 total points
ID: 24148411
I'm not using Server.Transfer, so the expert's comment doesn't really apply.

No satisfactory answers.
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

I have developed many web applications with asp & asp.net and to add and use a dropdownlist was always a very simple task, but with the new asp.net, setting the value is a bit tricky and its not similar to the old traditional method. So in this a…
User art_snob (http://www.experts-exchange.com/M_6114203.html) encountered strange behavior of Android Web browser on his Mobile Web site. It took a while to find the true cause. It happens so, that the Android Web browser (at least up to OS ver. 2.…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now