Solved

Generic Dictionary Change Value?

Posted on 2009-05-18
5
375 Views
Last Modified: 2012-05-07
I've been trying to chage a value in a Generic Dictionary, but no change or error occurs. I've found only this link concerning updating Generic Dictionary values: http://msdn.microsoft.com/en-us/library/xfhwa508(VS.80).aspx

Dictionary<string, string> GenDictionary = new Dictionary<string, string>();

GenDictionary.Add("1","Testing");

if(GenDictionary.ContainsKey("1"))
{
    GenDictionary["1"] = "Hello";
}
0
Comment
Question by:pointeman
  • 3
  • 2
5 Comments
 
LVL 16

Accepted Solution

by:
ToddBeaulieu earned 250 total points
ID: 24413779
Works just fine as-is for me!
0
 

Author Comment

by:pointeman
ID: 24414001
Yes, it's puzzling....
0
 
LVL 16

Expert Comment

by:ToddBeaulieu
ID: 24414032
So then this question isn't really needed then, right, since there's no problem?!
0
 

Author Closing Comment

by:pointeman
ID: 31582658
Had to restart Visual Studio.... Thanks for checking my code example
0
 

Author Comment

by:pointeman
ID: 24416840
Only problem is my computer it seems...
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
Along with being a a promotional video for my three-day Annielytics Dashboard Seminor, this Micro Tutorial is an intro to Google Analytics API data.
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…

816 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

8 Experts available now in Live!

Get 1:1 Help Now