关于asp.net后台调用前台刷新问题 意思是用alert弹框后..点击确定后刷新了页面? 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 同意3楼,大概代码bool hasRight = gs.CheckUserPopedom(HttpContext.Current.User.Identity.Name, ModelID, ref v); if (!hasRight) { Page.ClientScript.RegisterClientScriptBlock(Page.GetType(), "error", "$(document).ready(function(){alert('无权访问!');location.href='/NoAccess.aspx';});", true); return; } [img=C:\Documents and Settings\user\桌面\未命名.bmp][/img if (ViewState["userRole"].ToString() == "0") { Response.Redirect("GiftInfo.aspx?proid=" + e.CommandArgument.ToString() + ""); //this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "change('zulinGift','companyGift','personGift');changeImg('zuImg','comImg','perImg');", true); } else if (ViewState["userRole"].ToString() == "1") { // this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "$(document).ready(function(){alert('无权访问!');});", true); this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "window.alert('您无法兑换租赁商家礼品!');change('zulinGift','companyGift','personGift');changeImg('zuImg','comImg','perImg');", true); } else if (ViewState["userRole"].ToString() == "2") { this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "window.alert('您无法兑换租赁商家礼品!');change('zulinGift','companyGift','personGift');changeImg('zuImg','comImg','perImg');", true); } else { this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "window.alert('您无法兑换租赁商家礼品!');change('zulinGift','companyGift','personGift');changeImg('zuImg','comImg','perImg');", true); } 就是这段代码 MVC+Spring.net+Nhibernate如何分页? 怎么给方法里的方法传参数? 弱问: 页面加载时,怎么计算加载的数据量啊?我想计算页面加载时的下载数据量。。。 刚才程序其他代码太多了,大家看不清,现重开一贴,如何优化 asp.net中session如何设置 好奇怪得问题!!!!!!!!CELL里面为什么不能包含CHECKBOX 用过DataGrid分页的请进,一个思想问题! 如何自定义一个DataGrid配色样式啊? 关于控件的焦点的问题 CDO组件发送邮件问题,请指教 获取客户端IP地址 javascript 如何获得td里的标签?
bool hasRight = gs.CheckUserPopedom(HttpContext.Current.User.Identity.Name, ModelID, ref v); if (!hasRight) {
Page.ClientScript.RegisterClientScriptBlock(Page.GetType(), "error", "$(document).ready(function(){alert('无权访问!');location.href='/NoAccess.aspx';});", true);
return;
}
{
Response.Redirect("GiftInfo.aspx?proid=" + e.CommandArgument.ToString() + "");
//this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "change('zulinGift','companyGift','personGift');changeImg('zuImg','comImg','perImg');", true);
}
else if (ViewState["userRole"].ToString() == "1")
{
// this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "$(document).ready(function(){alert('无权访问!');});", true);
this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "window.alert('您无法兑换租赁商家礼品!');change('zulinGift','companyGift','personGift');changeImg('zuImg','comImg','perImg');", true);
}
else if (ViewState["userRole"].ToString() == "2")
{
this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "window.alert('您无法兑换租赁商家礼品!');change('zulinGift','companyGift','personGift');changeImg('zuImg','comImg','perImg');", true);
}
else
{ this.Page.ClientScript.RegisterStartupScript(Page.GetType(), "", "window.alert('您无法兑换租赁商家礼品!');change('zulinGift','companyGift','personGift');changeImg('zuImg','comImg','perImg');", true); } 就是这段代码