您目前尚未登陆,请选择【登陆】或【注册
首页->行政办公->网上办公系统源码>>BBS/BBS_Edit.aspx.cs>>代码在线查看
温馨提示:代码在线浏览功能只能做为源码浏览参考,不能展示项目的全部,如果想更进一步了解该代码请下载:网上办公系统源码


当前文件路径:OfficeOnline/BBS/BBS_Edit.aspx.cs 文件类型
普通视图
		            
1using System; 2using System.Data; 3using System.Configuration; 4using System.Collections; 5using System.Web; 6using System.Web.Security; 7using System.Web.UI; 8using System.Web.UI.WebControls; 9using System.Web.UI.WebControls.WebParts; 10using System.Web.UI.HtmlControls; 11 12public partial class BBS_BBS_Edit : System.Web.UI.Page 13{ 14 WebService webService = new WebService(); 15 string strSql; 16 protected void Page_Load(object sender, EventArgs e) 17 { 18 if (Session["UserID"] == null || Session["UserLevel"] == null) 19 { 20 Response.Redirect("~/Error.aspx"); 21 } 22 if (!Page.IsPostBack) 23 { 24 strSql = "Select BM_Title,BM_Content,BM_AddPersonID from z_BbsMessage where BM_ID='" + Request.QueryString["bid"] + "';"; 25 DataTable table = webService.ExcuteSelect(strSql); 26 this.tbTitle.Text = table.Rows[0]["BM_Title"].ToString(); 27 this.tbContent.Text = table.Rows[0]["BM_Content"].ToString(); 28 if(table.Rows[0]["BM_AddPersonID"].ToString()!=Session["UserID"].ToString()) 29 { 30 Response.Redirect("~/Error.aspx"); 31 } 32 } 33 } 34 protected void btnSubmit_Click(object sender, EventArgs e) 35 { 36 strSql = "Update z_BbsMessage set BM_Title='" + this.tbTitle.Text + "',BM_Content='" + this.tbContent.Text + "',BM_ModifyDate='" + DateTime.Now + "' where BM_ID='" + Request.QueryString["bid"] + "';"; 37 webService.ExcuteSql(strSql); 38 Response.Redirect("BBS_Info.aspx?bid="+Request.QueryString["bid"]); 39 } 40 protected void btnCancel_Click(object sender, EventArgs e) 41 { 42 Response.Redirect("BBS_Info.aspx?bid=" + Request.QueryString["bid"]); 43 } 44} 45
还没有找到您心仪的内容?请用.net源码大搜捕
代码片断 打包下载该项目完整源码:网上办公系统源码

- Asp.net试题素材管理系统源码

- 智能选课系统源码

- 苏州某纸业公司网站全站源码

- Vb.net网上订票系统源码

- 明日B2C电子商务系统源码

- 北京连锁超市会员积分销售系..

- 都市网络新闻中心系统源码

- 漂亮许愿墙前台程序源码

51Aspx.com 版权所有 CopyRight © 2000-2008. 京ICP备06046876号