这妞不错!

会有那么一天...

  博客园 :: 首页 :: 博问 :: 闪存 :: 新随笔 :: 联系 :: 订阅 订阅 :: 管理 ::

2012年11月24日

摘要: //判断读取到的文本中,是否有重复的项 var linq = from s in list group s by new { s.Code } into newGroup where newGroup.Count() > 1 select newGroup; if (linq.ToList().Count > 0) { MessageBox.Show("有重复的项,请检查!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Warning); return; } #region 定义导入对象 /// & 阅读全文
posted @ 2012-11-24 11:45 这妞不错 阅读(2806) 评论(0) 推荐(0)

摘要: //ps:txt导入文本格式导入单号(判断),单号,数值,导入数量(判断)CL2012110200416,MD132479864,0,20#region 方法--扫描导入 /// <summary> /// 方法--扫描导入 /// </summary> private void Import() { OpenFileDialog openFileDialog = new OpenFileDialog(); openFileDialog.Filter = "文本文件(*.txt)|*.txt|所有文件(*.*)|*.*"; openFileDialo 阅读全文
posted @ 2012-11-24 11:40 这妞不错 阅读(2345) 评论(1) 推荐(0)

摘要: if (txtEmployeeName.Text.Trim() != "" )//姓名 精确查询 { if (dgvInfoB["EMPLOYEENAME", i].Value.ToString().Trim() == txtEmployeeName.Text.Trim())//表格中的数据==查询条件 { dgvInfoB.CurrentCell = dgvInfoB["EMPLOYEENAME", i]; dgvInfoB.Rows[i].Selected = true;//选中行 break; } } 阅读全文
posted @ 2012-11-24 11:36 这妞不错 阅读(6953) 评论(0) 推荐(0)