private void Button_add_Click(object sender, RoutedEventArgs e)
 {
     if (SupportedPrivList.SelectedItem != null)
     {
         var item = SupportedPrivList.SelectedItem.ToString();
         SupportPrivilegeList.Remove(item);
         AddedPrivilegeList.Add(item);
     }
 }
        private void CreateSupportPrivList(List <string> privilegeList, List <appdefprivilege> appdefprivList, datacontrol dataControl = null)
        {
            foreach (var item in PrivilegeItems)
            {
                SupportPrivilegeList.Add(item.privilegeName);
            }

            foreach (var item in appdefprivList)
            {
                SupportPrivilegeList.Add(item.Value);
            }

            if (dataControl != null)
            {
                List <string> ExistList = dataControl.privilegeList;
                foreach (var item in ExistList)
                {
                    SupportPrivilegeList.Remove(item);
                }
            }
        }