2008年6月4日
摘要: 今天因为程序需要运行一个EUR软件来打印条形码,必须在程序中调用cmd.exe来运行EUR软件附带的文本格式转换程序eurps.exe,在网上查了一下,调试成功。。。下面是代码1protectedvoidBu_SmallBarcode_Click(objectsender,EventArgse)2{3strings=RunCmd("cdC:\\ProgramFiles\\HITACHI\\EURP... 阅读全文
posted @ 2008-06-04 11:09 romce 阅读(1027) 评论(0) 推荐(0) 编辑
  2008年4月11日
摘要: JAVASCRIPT二维数组(实例) 通过声明二维数组绑定SELECT下拉菜单 ... 阅读全文
posted @ 2008-04-11 16:10 romce 阅读(16118) 评论(2) 推荐(0) 编辑
摘要: ///用户数据结构 function _tagUser() { this.UserId = 0; //0-4 this.UserName = ""; //5- this.Parse = function(VarTypeUser) { for (var i=0;i VarTypeUser[i] = String.fromCharCode(VarTypeUser.charCodeAt(i)^0xFFFF); this.UserId = VarTypeUser.substr(0,4); //0-4 this.UserName = VarTypeUser.substr(5); //4-- } 阅读全文
posted @ 2008-04-11 14:50 romce 阅读(19656) 评论(1) 推荐(2) 编辑
  2008年4月10日
摘要: DataGrid 通过内部控件获取所在控件的列索引, 原来以为列所引很容易通过属性得到,没想到费了一番周转,花了不少时间,太过费劲了,不知有更简单的方法没? foreach (DataGridItem i in this.DtGrid.Controls[0].Controls) { if (i.ItemType == ListItemType.Header) { for (int month_i = 1; month_i { Label myLabel = (Label)i.FindControl("lblMonth" + month_i.ToString()); myLabel.Text = myYear. 阅读全文
posted @ 2008-04-10 12:41 romce 阅读(686) 评论(0) 推荐(0) 编辑
  2008年4月8日
摘要: //对应年月的预算映射 string[] budgetArray = new string[12]; string[] actArray = new string[12]; budgetArray[0] = vi.Rows[i][vi.Budget1Column.ColumnName].ToString(); budgetArray[1] = vi.Rows[i][vi.Budget2Column.ColumnName].ToString(); budgetArray[2] = vi.Rows[i][vi.Budget3Column.ColumnName].ToString(); budgetArray[3] = vi.Rows[i][vi.Budget4Column.ColumnName].ToString(); 阅读全文
posted @ 2008-04-08 12:39 romce 阅读(263) 评论(0) 推荐(0) 编辑
  2008年4月7日
摘要: //纵列合计 DS_PlanPrice.vi_PlanPriceRow drTotal = vi.Newvi_PlanPriceRow(); drTotal.ProductId = Convert.ToString(dtProduct.Rows[i][dtProduct.ProductIdColumn.ColumnName]); drTotal.PriceTypeName = "Total"; foreach (DS_PlanPrice.vi_PlanPriceRow vRow in vi.Rows) { if (vRow.ProductId == dtProduct.Rows[i][dtProduct.ProductIdColumn.ColumnName].ToString()) 阅读全文
posted @ 2008-04-07 12:43 romce 阅读(2415) 评论(0) 推荐(0) 编辑
  2008年4月3日
摘要: readonly 关键字与 const 关键字不同。 1. const 字段只能在该字段的声明中初始化。 readonly 字段可以在声明或构造函数中初始化。因此,根据所使用的构造函数,readonly 字段可能具有不同的值。 2. const 字段是编译时常数,而 readonly 字段可用于运行时常数。 3. const 默认就是静态的,而 readonly 如果设置成静态的就必须显示声明。 阅读全文
posted @ 2008-04-03 01:20 romce 阅读(237) 评论(0) 推荐(1) 编辑
  2008年3月25日
摘要: 一个日期控件 感觉不错 没准项目可以用得到http://www.cnblogs.com/my97/archive/2008/03/25/1121408.html 阅读全文
posted @ 2008-03-25 16:35 romce 阅读(242) 评论(0) 推荐(0) 编辑
摘要: /// /// 在页面显示出对应的年月 /// protected void YearMonthBind(string companyID, int startMonth) { int myYear = Convert.ToInt32(dropYear.SelectedValue); int myMonth = startMonth; foreach (DataGridItem i in this.DtGrid.Controls[0].Controls) { 阅读全文
posted @ 2008-03-25 13:54 romce 阅读(181) 评论(0) 推荐(0) 编辑
  2008年3月21日
摘要: 定义类的两种基本方式: (1) 利用函数构造类型。 function Foo(text, url) { this.text = text; this.url = url; this.render = function() { document.write('' + this.text + ''); } } 阅读全文
posted @ 2008-03-21 16:00 romce 阅读(225) 评论(0) 推荐(0) 编辑