public void Initialize() { string[] vrList = DHelper.GetVRNames(); string[] tagList = DHelper.GetTagNames(); this._comboxBoxTag.Items.Add(""); this._comboxBoxTag.SelectedIndex = 0; foreach (string tag in tagList) { this._comboxBoxTag.Items.Add(tag); } foreach (string vr in vrList) { this._comboxBoxVR.Items.Add(vr); } if (this._comboxBoxVR.Items.Count > 0) { this._comboxBoxVR.SelectedIndex = 0; } }
private static List <VrItem> GetVrItemList() { string[] tagList = DHelper.GetVRNames(); SortedList <string, VrItem> slist = new SortedList <string, VrItem>(); foreach (string str in tagList) { VrItem ti = new VrItem(); ti.EnumName = str; ti.VR = (DVR)DHelper.GetVR(str); ti.DisplayName = (ti.VR == DVR.Unknown) ? "" : str; slist.Add(ti.DisplayName, ti); } List <VrItem> tlist = new List <VrItem>(); foreach (KeyValuePair <string, VrItem> p in slist) { tlist.Add(p.Value); } return(tlist); }