ab56a9bcf7
SVN-Revision: r240
46 lines
1.1 KiB
C#
46 lines
1.1 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel;
|
|
using System.Data;
|
|
using System.Drawing;
|
|
using System.Text;
|
|
using System.Linq;
|
|
using System.Threading.Tasks;
|
|
using System.Windows.Forms;
|
|
using DevExpress.XtraEditors;
|
|
|
|
namespace CsHospital
|
|
{
|
|
public partial class WardSelec : DevExpress.XtraEditors.XtraForm
|
|
{
|
|
public string f_zyh = "";
|
|
|
|
public WardSelec(DataTable dt) {
|
|
InitializeComponent();
|
|
gridControl1.DataSource = dt;
|
|
|
|
this.gridView1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.GridView_KeyDown);
|
|
|
|
}
|
|
|
|
private void btn_add_Click(object sender, EventArgs e)
|
|
{
|
|
DataRow dr = gridView1.GetDataRow(gridView1.FocusedRowHandle);
|
|
f_zyh = dr["住院号"] + "";
|
|
this.Close();
|
|
this.DialogResult = System.Windows.Forms.DialogResult.OK;
|
|
}
|
|
private void GridView_KeyDown(object sender, KeyEventArgs e)
|
|
{
|
|
if (e.KeyCode == Keys.Enter)
|
|
{
|
|
btn_add_Click(sender,e);
|
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
} |