/// <summary> /// 刷新 /// </summary> /// <param name="BeginDate"></param> /// <param name="EndDate"></param> public void m_mthRefresh(string BeginDate, string EndDate) { if (!this.m_blnGetEmpIDName()) { return; } this.Cursor = Cursors.WaitCursor; DataTable dt; clsDcl_Charge objCharge = new clsDcl_Charge(); long l = objCharge.m_lngGetDayReckoningTime(EmpID, BeginDate, EndDate, out dt); if (l > 0) { this.lvHistory.BeginUpdate(); this.lvHistory.Items.Clear(); hasRecDate1 = new Hashtable(); hasRecDate2 = new Hashtable(); for (int i = 0; i < dt.Rows.Count; i++) { ListViewItem lv = new ListViewItem(Convert.ToString(i + 1)); lv.SubItems.Add(dt.Rows[i]["recdate"].ToString().Trim()); lv.Tag = dt.Rows[i]["recdate"].ToString().Trim(); this.lvHistory.Items.Add(lv); hasRecDate1.Add(dt.Rows[i]["recdate"].ToString().Trim(), i.ToString()); hasRecDate2.Add(i.ToString(), dt.Rows[i]["recdate"].ToString().Trim()); } this.lvHistory.EndUpdate(); } this.Cursor = Cursors.Default; if (dt.Rows.Count == 0) { MessageBox.Show("在指定的时间段内,该收款员没有日帐记录。", "系统提示", MessageBoxButtons.OK, MessageBoxIcon.Information); } }