i am presently using hard coded values and applying foreach loop to them but now i want to store those values in xml and get the values from xml wrt key..\[code\] int[] codesList = { 172, 204, 221 }; foreach (var code in codesList) { TagVisualizationDefinition tagVisualizationDefinition = new TagVisualizationDefinition(); tagVisualizationDefinition.Value = http://stackoverflow.com/questions/14562139/code; tagVisualizationDefinition.Source = new Uri("TagVisualization1.xaml", UriKind.Relative); tagVisualizationDefinition.UsesTagOrientation = true; tagVisualizationDefinition.TagRemovedBehavior = TagRemovedBehavior.Fade; tagVisualizationDefinition.PhysicalCenterOffsetFromTag = new Vector(7.5, 4.5); TagVisualizer.Definitions.Add(tagVisualizationDefinition); }\[/code\]i have to add these codes to xml file and then right now i am checking for the key using switch statement but npw i want to use key value in xml.\[code\]switch (VisualizedTag.Value) { // For CC case 204: webBrowser1.Navigate(new Uri("http://www.microsoft.com")); break; //For AC case 172: webBrowser1.Navigate(new Uri("http://www.msdn.com")); break; //For DD case 221: webBrowser1.Navigate(new Uri("http://www.technet.com")); break; default: MessageBox.Show("HexCode Not Found"); break; }\[/code\]i want to check for xml key if it matches then apply there value.xml format : add key ="204 " value ="http://www.microsoft.com" thanks in advance, do tell me if you needed more explanation of the scenario.