57 lines
1.9 KiB
C#
57 lines
1.9 KiB
C#
using DCSoft.Writer.Dom;
|
|
using DevComponents.DotNetBar.Controls;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel;
|
|
using System.Data;
|
|
using System.Drawing;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Windows.Forms;
|
|
|
|
namespace DocumentManagement.UI
|
|
{
|
|
public partial class ShowPacsText : Form
|
|
{
|
|
public string PatientNo;
|
|
public XTextInputFieldElement element;
|
|
public ShowPacsText()
|
|
{
|
|
InitializeComponent();
|
|
}
|
|
|
|
private void ShowPacsText_Load(object sender, EventArgs e)
|
|
{
|
|
dgvItems.AutoGenerateColumns = false;
|
|
dgvItems.RowsDefaultCellStyle.WrapMode = DataGridViewTriState.True;
|
|
dgvItems.AutoSizeRowsMode = DataGridViewAutoSizeRowsMode.AllCellsExceptHeaders;
|
|
DataTable lisdate = DocumentDAL.GetPacsResultItems(PatientNo);
|
|
dgvItems.DataSource = lisdate;
|
|
}
|
|
|
|
private void dgvItems_CellClick(object sender, DataGridViewCellEventArgs e)
|
|
{
|
|
dgvItems.BeginEdit(true);
|
|
this.dgvItems.CellMouseUp -= new System.Windows.Forms.DataGridViewCellMouseEventHandler(this.dgvItems_CellMouseUp);
|
|
this.dgvItems.CellMouseUp += new System.Windows.Forms.DataGridViewCellMouseEventHandler(this.dgvItems_CellMouseUp);
|
|
txtSelText.Text = "";
|
|
}
|
|
|
|
private void buttonX1_Click(object sender, EventArgs e)
|
|
{
|
|
element.Text = txtSelText.Text.Replace("\n","");
|
|
this.Close();
|
|
}
|
|
|
|
private void dgvItems_CellMouseUp(object sender, DataGridViewCellMouseEventArgs e)
|
|
{
|
|
string SelectedText = ((System.Windows.Forms.TextBoxBase)((System.Windows.Forms.DataGridView)sender).EditingControl).SelectedText;
|
|
if (SelectedText != "")
|
|
txtSelText.Text = SelectedText;
|
|
else
|
|
txtSelText.Text = "-";
|
|
|
|
}
|
|
}
|
|
}
|