Exemplo n.º 1
0
        private void lstvInParameter_DoubleClick(object sender, EventArgs e)
        {
            int selectIndex = lstvInParameter.SelectedIndices[0];
            int itemIndex   = (int)lstvInParameter.SelectedItems[0].Tag;

            QueryInParameter frm = new QueryInParameter(criteriaList, itemIndex);

            frm.ShowDialog(this);

            ShowCriteriaList();
            lstvInParameter.Items[selectIndex].Selected = true;
        }
Exemplo n.º 2
0
        private void btnInParameterAdd_Click(object sender, EventArgs e)
        {
            int count = criteriaList.Count;

            QueryInParameter frm = new QueryInParameter(criteriaList);

            frm.ShowDialog(this);

            if (criteriaList.Count > count)
            {
                ShowCriteriaList();
                int i = 0;
                foreach (ListViewItem viewItem in lstvInParameter.Items)
                {
                    if ((int)viewItem.Tag == count)
                    {
                        lstvInParameter.Items[i].Selected = true;
                        break;
                    }
                    i++;
                }
            }
        }