Exemple #1
0
        private void btnFieldAdd_Click(object sender, EventArgs e)
        {
            frmEditField frm = new frmEditField();

            if (frm.ShowDialog() == DialogResult.OK)
            {
                lstFields.AppendItem(frm.Field);
                dataFileManager1.IsModified = true;
            }
        }
Exemple #2
0
        private void btnFieldEdit_Click(object sender, EventArgs e)
        {
            int index = lstFields.SelectedIndex;

            if (index >= 0)
            {
                frmEditField frm = new frmEditField(lstFields.Items[index] as Field);
                if (frm.ShowDialog() == DialogResult.OK)
                {
                    lstFields.ReplaceItem(frm.Field);
                    dataFileManager1.IsModified = true;
                }
            }
        }