摘要: var list = from staff in staffList from extraRecord in extraList where staff.staffID == extraRecord.staffID && staff.staffID != Loginer.staffID && extraRecord.depOpinion == null select extraRecord;private IList mySort(IList list) { var tempLi... 阅读全文
posted @ 2014-01-27 17:06 aswater 阅读(198) 评论(0) 推荐(0) 编辑
摘要: public class ValidateCode : WebControl { /// /// 默认构造函数,暴露的属性接口 /// public ValidateCode() { this.... 阅读全文
posted @ 2014-01-27 17:01 aswater 阅读(971) 评论(0) 推荐(0) 编辑
摘要: 1.标签的使用Loginer.images是图片的路径 this.images.ImageUrl = "showImg.aspx?imgFile="+ Loginer.images;2.添加一个新的页面showImg.aspx,在后台代码写 private string file = string.... 阅读全文
posted @ 2014-01-27 16:51 aswater 阅读(305) 评论(0) 推荐(0) 编辑
摘要: 网上找到的发送邮件的类,改了一点点,在此谢谢原作者的奉献。1.源码: public class CSendMail { private MailMessage mailMessage; private SmtpClient smtpClient; ... 阅读全文
posted @ 2014-01-27 16:40 aswater 阅读(517) 评论(0) 推荐(0) 编辑
摘要: 同事的代码,帮忙修改的,为了实现页面跳转回来后,状态的保持,Service 使用了Session。 主要的JS $.ajax({ url: "/ws/StaffInfo.asmx/Note",//路径/方法 type: "POST", contentType: "application/json", data: "{id:'" + id + "',sex:'" + sex + "',dep:'" + dep + "', 阅读全文
posted @ 2014-01-27 16:32 aswater 阅读(333) 评论(0) 推荐(0) 编辑
摘要: /// /// 下载附件查看 /// /// /// protected void downButton_Command(object sender, CommandEventArgs e) { //传递过来的参数 string fullName = e.CommandArgument.ToString(); string fileName=System.IO.Path.GetFileName(fullName); ... 阅读全文
posted @ 2014-01-27 16:17 aswater 阅读(214) 评论(0) 推荐(0) 编辑
摘要: 功能:可以实现导出整个数据表格或整个页面public bool ExportGv(string fileType, string fileName) { bool flag = false; try { //定义文档类型、字符编码 Response.Clear(); Response.Buffer = true; HttpContext.Current.Response.Charset = "GB2312"; HttpContext.Current.Response.ContentEncoding = System.Text.Encoding.GetEncoding(&qu 阅读全文
posted @ 2014-01-27 16:11 aswater 阅读(634) 评论(0) 推荐(1) 编辑
摘要: 在GridView中隐藏一字段,方便这条记录的处理,同时隐藏一个Button实现点击这条记录时的处理1.绑定 是否批准 待定 同意 不同意 '> 2.处理 实现光棒效果,并注册这条记录点击时的处理 protected void Gv_RowDataBound(object sender, GridViewRowEventArgs e) { Button btn = e.Row.FindControl("hiddenPost") as Button; if (btn != null) { e.Row.Attributes["onclick"] 阅读全文
posted @ 2014-01-27 15:57 aswater 阅读(346) 评论(0) 推荐(0) 编辑