| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140 |
- 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;
- using CoreFS.CA06;
- using System.Collections;
- namespace Core.LZMes.Client.UIK
- {
- public partial class UIK080010 : FrmBase
- {
- public UIK080010()
- {
- InitializeComponent();
- }
- #region 处理化处理
- private void UIK080011_Load(object sender, EventArgs e)
- {
-
- this.ultraDateTimeEditor1.Enabled = false;
- this.ultraDateTimeEditor2.Enabled = false;
- }
- #endregion
- #region 工具栏点击处理
- public override void ToolBar_Click(object sender, string ToolbarKey)
- {
- switch (ToolbarKey)
- {
- case "Query":
- this.DoQuery();
- break;
-
- }
- }
- #endregion
- #region 查询方法
- public void DoQuery() {
- try
- {
- string start = this.ultraDateTimeEditor1.DateTime.ToString("yyyyMMdd") + "000000";
- string end = this.ultraDateTimeEditor2.DateTime.ToString("yyyyMMdd") + "595959";
- string number = this.textBox1.Text;
- bool flag = true;
- CoreClientParam ccp = new CoreClientParam();
- if (this.ultraCheckEditor1.Checked == false && this.ultraCheckEditor2.Checked == false)
- {
- MessageBox.Show("请选择查询条件!");
- }
- else
- {
- if (this.ultraCheckEditor1.Checked)
- {
- this.dataSet1.Tables[0].Clear();
- this.ultraCheckEditor1.Checked = false;
- ccp.ServerName = "UIK.UIK08.UIK080010";
- ccp.MethodName = "DoQuery";
- ccp.ServerParams = new object[] { start, end,number, flag };
- ccp.SourceDataTable = this.dataSet1.Tables[0];
- this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
- DataRowCollection drc1 = this.dataSet1.Tables[0].Rows;
- if (drc1.Count <= 0)
- {
- MessageBox.Show("无记录!");
- }
- this.ultraDateTimeEditor1.Enabled = false;
- this.ultraDateTimeEditor2.Enabled = false;
- this.ultraCheckEditor2.Checked = false;
- return;
- }
- if (this.ultraCheckEditor2.Checked)
- {
-
- flag = false;
- this.dataSet1.Tables[0].Clear();
- this.ultraCheckEditor2.Checked = false;
- ccp.ServerName = "UIK.UIK08.UIK080010";
- ccp.MethodName = "DoQuery";
- ccp.ServerParams = new object[] { start, end, number, flag };
- ccp.SourceDataTable = this.dataSet1.Tables[0];
- this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
- DataRowCollection drc1 = this.dataSet1.Tables[0].Rows;
- if (drc1.Count <= 0)
- {
- MessageBox.Show("无记录!");
- }
- return;
- }
- }
- }catch(Exception Ex){
- MessageBox.Show(Ex.ToString());
- }
- }
- #endregion
- #region 选框1点击处理
- private void ultraCheckEditor1_CheckedChanged(object sender, EventArgs e)
- {
- if (this.ultraCheckEditor1.Checked){
- this.ultraDateTimeEditor1.Enabled = true;
- this.ultraDateTimeEditor2.Enabled = true;
- this.ultraCheckEditor2.Checked= false;
- }
- else {
- this.ultraDateTimeEditor1.Enabled = false;
- this.ultraDateTimeEditor2.Enabled = false;
- }
- }
- #endregion
- #region 选框2点击处理
- private void ultraCheckEditor2_CheckedChanged(object sender, EventArgs e)
- {
- if (this.ultraCheckEditor2.Checked) {
- this.ultraCheckEditor1.Checked = false;
- this.ultraDateTimeEditor1.Enabled = false;
- this.ultraDateTimeEditor2.Enabled = false;
- }
- }
- #endregion
- }
- }
|