I have
Dictionary<string,string> keyValList;
its data looks like:
<"{1}" , "TEXT NUMBER 1">
<"{2}" , "TEXT NUMBER 2">
<"{3}" , "TEXT NUMBER 3">
<"{4}" , "TEXT NUMBER 4">
<"{5}" , "TEXT NUMBER 5">
<"{5}" , "TEXT NUMBER 6">
I have List of objects that has this text in it:
Item item1 = new Item();
item1.Tooltip = "{1}";
item1.Label= "{2}";
item1.Error= "{3}";
Item item2 = new Item();
item2.Tooltip = "{4}";
item2.Label= "{5}";
item2.Error= "{6}";
List<Item> items = new List<Item>();
items.Add(item1);
items.Add(item2);
What is the smartest way to make items(!) look like this:
item1.Tooltip = "TEXT NUMBER 1";
item1.Label= "TEXT NUMBER 2";
item1.Error= "TEXT NUMBER 3";
item2.Tooltip = "TEXT NUMBER 4";
item2.Label= "TEXT NUMBER 5";
item2.Error= "TEXT NUMBER 6";
I am looking in to an efficiant way, because this is just an example, the items and keyValList are bigger.
Thanks
Why you wanna do that in linq ?