Пример #1
0
        private void Edit()
        {
            QueryCriteriaItem item = GetSelectedItem();

            if (item == null)
            {
                return;
            }

            FormQCItem frm = new FormQCItem(item, _message.QueryCriterias);

            if (frm.ShowDialog(this) != DialogResult.OK)
            {
                return;
            }

            RefreshList();
            SelectItem(item);
        }
Пример #2
0
        private void Add()
        {
            FormQCItem frm = new FormQCItem(null, _message.QueryCriterias);

            if (frm.ShowDialog(this) != DialogResult.OK)
            {
                return;
            }

            QueryCriteriaItem item = frm.QCItem;

            if (item == null)
            {
                return;
            }

            _message.QueryCriterias.Add(item);

            RefreshList();
            SelectItem(item);
        }