Beispiel #1
0
        private void btnAliasAdd_Click(object sender, EventArgs e)
        {
            List <string> sAlias = new List <string>();

            foreach (object o in listAliases.Items)
            {
                sAlias.Add(o.ToString());
            }
            frmEditAliases dlg = new frmEditAliases(sAlias);

            if (dlg.ShowDialog() == DialogResult.OK)
            {
                listAliases.Items.Clear();
                foreach (string s in dlg.m_Aliases)
                {
                    listAliases.Items.Add(s);
                }
                listAliases.SelectedIndex = 0;
            }
            dlg.Dispose();
        }
        private void btnAliasAdd_Click(object sender, EventArgs e)
        {
            List<string> sAlias=new List<string>();
            foreach(object o in listAliases.Items)
                sAlias.Add(o.ToString());
            frmEditAliases dlg = new frmEditAliases(sAlias);
            if (dlg.ShowDialog() == DialogResult.OK)
            {
                listAliases.Items.Clear();
                foreach (string s in dlg.m_Aliases)
                    listAliases.Items.Add(s);
                listAliases.SelectedIndex = 0;
            }
            dlg.Dispose();

        }