コード例 #1
0
		private void buttonUseAutoNote_Click(object sender,EventArgs e) {
			FormAutoNoteCompose FormA=new FormAutoNoteCompose();
			FormA.ShowDialog();
			if(FormA.DialogResult==DialogResult.OK) {
				textAppended.AppendText(FormA.CompletedNote);
			}
		}
コード例 #2
0
ファイル: FormOrthoChart.cs プロジェクト: kjb7749/testImport
        private void butUseAutoNote_Click(object sender, EventArgs e)
        {
            if (gridMain.SelectedCell.X == -1 || gridMain.SelectedCell.X == 0 || gridMain.SelectedCell.X == _sigColIdx)
            {
                MsgBox.Show(this, "Please select an editable Ortho Chart cell first.");
                return;
            }
            if (HasPickList(gridMain.Columns[gridMain.SelectedCell.X].Heading))
            {
                MsgBox.Show(this, "Cannot add auto notes to a field with a pick list.");
                return;
            }
            FormAutoNoteCompose FormA = new FormAutoNoteCompose();

            FormA.ShowDialog();
            if (FormA.DialogResult == DialogResult.OK)
            {
                Point selectedCell = new Point(gridMain.SelectedCell.X, gridMain.SelectedCell.Y);
                //Add text to current focused cell
                gridMain.Rows[gridMain.SelectedCell.Y].Cells[gridMain.SelectedCell.X].Text += FormA.CompletedNote;
                //Since the redrawing of the row height is dependent on the edit text box built into the ODGrid, we have to manually tell the grid to redraw.
                //This will essentially "refresh" the grid.  We do not want to call FillGrid() because that will lose data in other cells that have not been saved to datatable.
                if (_showSigBox && FormA.CompletedNote != "")
                {
                    signatureBoxWrapper.ClearSignature();
                    SaveSignatureToDict(gridMain.SelectedCell.Y);
                    DisplaySignature(gridMain.SelectedCell.Y);
                }
                gridMain.BeginUpdate();
                gridMain.EndUpdate();
                gridMain.SetSelected(selectedCell);
                _hasChanged = true;
            }
        }
コード例 #3
0
        private void butUseAutoNote_Click(object sender, EventArgs e)
        {
            FormAutoNoteCompose FormA = new FormAutoNoteCompose();

            FormA.ShowDialog();
            if (FormA.DialogResult == DialogResult.OK)
            {
                textValue.AppendText(FormA.CompletedNote);
            }
        }
コード例 #4
0
        private void butAutoNote_Click(object sender, EventArgs e)
        {
            FormAutoNoteCompose FormA = new FormAutoNoteCompose();

            FormA.ShowDialog();
            if (FormA.DialogResult == DialogResult.OK)
            {
                textNote.Text += FormA.CompletedNote;
            }
        }
コード例 #5
0
        private void butAutoNote_Click(object sender, EventArgs e)
        {
            FormAutoNoteCompose FormA = new FormAutoNoteCompose();

            FormA.ShowDialog();
            if (FormA.DialogResult == DialogResult.OK)
            {
                textNote.AppendText(FormA.CompletedNote);
                butEditAutoNote.Visible = GetHasAutoNotePrompt();
            }
        }
コード例 #6
0
 private void butEditAutoNote_Click(object sender, EventArgs e)
 {
     if (GetHasAutoNotePrompt())
     {
         FormAutoNoteCompose FormA = new FormAutoNoteCompose();
         FormA.MainTextNote = textNote.Text;
         FormA.ShowDialog();
         if (FormA.DialogResult == DialogResult.OK)
         {
             textNote.Text           = FormA.CompletedNote;
             butEditAutoNote.Visible = GetHasAutoNotePrompt();
         }
     }
     else
     {
         MessageBox.Show(Lan.g(this, "No Auto Note available to edit."));
     }
 }
コード例 #7
0
ファイル: FormOrthoChart.cs プロジェクト: mnisl/OD
		private void butUseAutoNote_Click(object sender,EventArgs e) {
			if(gridMain.SelectedCell.X==-1 || gridMain.SelectedCell.X==0) {
				MsgBox.Show(this,"Please select an editable Ortho Chart cell first.");
				return;
			}
			FormAutoNoteCompose FormA=new FormAutoNoteCompose();
			FormA.ShowDialog();
			if(FormA.DialogResult==DialogResult.OK) {
				//Add text to current focused cell				
				gridMain.Rows[gridMain.SelectedCell.Y].Cells[gridMain.SelectedCell.X].Text+=FormA.CompletedNote;
				//Since the redrawing of the row height is dependent on the edit text box built into the ODGrid, we have to manually tell the grid to redraw.
				//This will essentially "refresh" the grid.  We do not want to call FillGrid() because that will lose data in other cells that have not been saved to datatable.
				gridMain.BeginUpdate();
				gridMain.EndUpdate();
				_hasChanged=true;
			}
		}