I want to save a NameValueCollection that can be used later in my winForm Application. The thing is, I want to user to be able to specify the name of the NVC and then it will save each name and value within that user specified NVC. Then I'll store the name that they gave the NVC into a listBox and if they want to edit anything later, they can just select the name in the listBox and it will show all of the names and values within that NVC.
I know how to do everything except, allowing the user to name the NVC and I don't know how to have access to it later.
Need help with NameValueCollection
3 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Diptimaya PatraRank #113 · 19.8K pointsPosted Feb 15, 2010, 4:43 PM EST
You can use app.config to store NVC. Just go to your project properties and you would find "Settings" tab. There you can set your Collection name. I am not sure about Dictionary object but it supports Collection of String, so you can have two collections with names such as Name and Value.
This is the easiest solution I have experienced.
Thanks
Diptimaya Patra
--------------------------------------------
MARK IT AS ANSWER IF IT HELPS
Jacob R26 pointsPosted Feb 15, 2010, 4:48 PM EST
Jacob R26 pointsPosted Feb 15, 2010, 5:01 PM EST