hello

04 2012 档案

摘要:引用MVCPaging.dll来进行分页,不过不同的MVC的版本一定要下载不同的MVCPaging.dll来使用。否则在MVC3里面会不兼容的。Controller: using MvcPaging; public ActionResult Index(int? page) { var list = VideoRepository.FindAll().OrderByDescending(v => v.CreateTime); return View(list.ToPagedList(page.HasValue ? page.Value - 1 : 0, 3... 阅读全文
posted @ 2012-04-30 02:15 B追风少年 阅读(1123) 评论(2) 推荐(0)
摘要:最近新装了vs2010,发现打开vs2010 后 起始页面中的最近使用的栏目中 并未显示最近加载的项目解决办法如下:运行 regedit 打开下面的键值: HKEY_CURRENT_USER/Software/Microsoft/Windows/CurrentVersion/Policies/Explorer 将 NoRecentDocsHistory 设置为 0 阅读全文
posted @ 2012-04-28 14:48 B追风少年 阅读(506) 评论(0) 推荐(0)
摘要:asp.net页面中,如下方法给DropDownList赋值: dpType.SelectedIndex = dpType.Items.IndexOf(dpType.Items.FindByText(m_TradeReport.R_CateName));或dpType.SelectedIndex = dpType.Items.IndexOf(dpType.Items.FindByValue(m_TradeReport.R_CateID));这两个可以避免以下方法有时候不能设置值的情况: dpType.SelectedValue = Convert.ToString(m_TradeReport. 阅读全文
posted @ 2012-04-28 14:46 B追风少年 阅读(948) 评论(0) 推荐(0)
摘要:1.文本框1.1 <input type="text" name="test" id="test">通过var t=document.getElementById("test").value把值赋给变量t,1.2 当然也可以反过来把已知的变量值赋给文本框,例如:var m = "5";document.getElementById("test").value= m;2.下拉列表框2.1 <select name="sel" id=&quo 阅读全文
posted @ 2012-04-27 14:35 B追风少年 阅读(3010) 评论(0) 推荐(0)

hello too