2012年8月29日

将查询结果赋值给文本框注意事项

摘要: 将查询结果赋值给文本框注意事项:frm_ClientCompanyInfo _frm = new frm_ClientCompanyInfo(userinfo.CompanyID.ToString());_frm.ShowDialog();txt_ClientCode.Text = _frm.CompanyCode;long_custrmerId = _frm.CompanyID;以上写法看起来似乎没有错误,但当txt_ClientCode文本框控件有 Text_Changed 事件时,以上写法当执行到 txt_ClientCode.Text = _frm.CompanyCode;后自动执行T 阅读全文

posted @ 2012-08-29 11:40 林中的鱼 阅读(356) 评论(0) 推荐(0) 编辑

2012年8月28日

缩写方法(new Set_AddGoodsInfoObject() { ClientID = _frm.ClientID })

摘要: 当查询时传递的参数是一个对象时,且对象中只有一个或不多于三个有值时,可以用缩写方法(new Set_AddGoodsInfoObject() { ClientID = _frm.ClientID })Set_AddGoodsInfoList = proxy.SelectInFoList(new Set_AddGoodsInfoObject() { ClientID = _frm.ClientID }); 阅读全文

posted @ 2012-08-28 23:47 林中的鱼 阅读(301) 评论(0) 推荐(0) 编辑

批量对TextBox控件禁用或清空

摘要: foreach (Control c in _frm.groupBox_Car.Controls) { if (c is TextBox) c.Enabled = false; if ( c is TextBox) c.text=""; } 阅读全文

posted @ 2012-08-28 23:40 林中的鱼 阅读(245) 评论(0) 推荐(0) 编辑

利用ArrayList去重

摘要: ArrayList jhd = new ArrayList();for (int i = 0; i < dgv_OutBoundOrder.RowCount; i++){if (dgv_OutBoundOrder.Rows[i].Cells["chk_choose"].EditedFormattedValue.ToString().ToUpper().Equals("TRUE")) { jhd.Add(dgv_OutBoundOrder.Rows[i].Cells["PickingGoodsID"].Value.ToString 阅读全文

posted @ 2012-08-28 23:34 林中的鱼 阅读(2318) 评论(0) 推荐(0) 编辑

从cmb中读取List数据源

摘要: List<Set_AddGoodsTypeObject> GoodsBigTypeList = (List<Set_AddGoodsTypeObject>)_frm.cmb_GoodsSmallType.DataSource; 阅读全文

posted @ 2012-08-28 23:29 林中的鱼 阅读(139) 评论(0) 推荐(0) 编辑

导航