private void AddElement(EhrRestrictionType restriction) { FormEhrPatListElementEdit FormPLEE=new FormEhrPatListElementEdit(); FormPLEE.Element=new EhrPatListElement(); FormPLEE.Element.Restriction=restriction; FormPLEE.IsNew=true; FormPLEE.ShowDialog(); if(FormPLEE.DialogResult==DialogResult.OK) { ElementList.Add(FormPLEE.Element); } FillGrid(); }
private void gridMain_CellDoubleClick(object sender,ODGridClickEventArgs e) { int index=gridMain.GetSelectedIndex(); if(index==-1) { MessageBox.Show("Please select a data element first."); return; } FormEhrPatListElementEdit FormPLEE=new FormEhrPatListElementEdit(); FormPLEE.Element=ElementList[index]; FormPLEE.ShowDialog(); if(FormPLEE.DialogResult==DialogResult.Cancel && FormPLEE.Delete) { ElementList.Remove(ElementList[index]); } FillGrid(); }
private void AddElement(EhrRestrictionType restriction) { FormEhrPatListElementEdit FormPLEE = new FormEhrPatListElementEdit(); FormPLEE.Element = new EhrPatListElement(); FormPLEE.Element.Restriction = restriction; FormPLEE.IsNew = true; FormPLEE.ShowDialog(); if (FormPLEE.DialogResult == DialogResult.OK) { ElementList.Add(FormPLEE.Element); } FillGrid(); }
private void gridMain_CellDoubleClick(object sender, ODGridClickEventArgs e) { int index = gridMain.GetSelectedIndex(); if (index == -1) { MessageBox.Show("Please select a data element first."); return; } FormEhrPatListElementEdit FormPLEE = new FormEhrPatListElementEdit(); FormPLEE.Element = ElementList[index]; FormPLEE.ShowDialog(); if (FormPLEE.DialogResult == DialogResult.Cancel && FormPLEE.Delete) { ElementList.Remove(ElementList[index]); } FillGrid(); }