在ASP.NET中的页面重定向 [英] page redirect in asp.net

查看:78
本文介绍了在ASP.NET中的页面重定向的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Web解决方案有两个页面审核摘要aspx和Caseinformationopt2.aspx都使用Commanheader标头用户控件.在Commanheader上有更新案例状态"链接,它也是用户控件,借助于此控件,我将更新案例在系统中的案例状态.在更新案例状态"控件上,具有btn_Save();当从审核摘要aspx"状态正确调用此方法时,它将在审核摘要aspx"上重定向.它是使用Server.Transfer(HttpContext.Current.Request.Url.LocalPath); LocalPath正确显示了/AuditSummary.aspx页面.但是当从CaseInfromation页面更新同一案例时,由于Option2文件夹中的Caseinformationopt2.aspx页面,将给我错误.它还在本地路径中使用Server.Transfer(HttpContext.Current.Request.Url.LocalPath),显示为/option2/Caseinformationopt2.aspx.

Web solution has two pages Audit summary aspx and Caseinformationopt2.aspx both page use Commanheader header user control.on Commanheader there is link ''Update Case Status'' it is also user control with the help of this control i will update case status of cases in the system.On ''Update Case Status'' control has btn_Save(); when call this method from Audit summary aspx status update properly it is redirect on Audit summary aspx. it is use Server.Transfer(HttpContext.Current.Request.Url.LocalPath); LocalPath shows /AuditSummary.aspx page properly.But when same case update from CaseInfromation page it will give me error beacuse of Caseinformationopt2.aspx page in Option2 folder. it also use Server.Transfer(HttpContext.Current.Request.Url.LocalPath) in local path it shows /option2/Caseinformationopt2.aspx. how solved this problem.

推荐答案

添加它以将其从未答复"队列中删除. OP自己解决了.
Adding this to remove it from Unanswered queue. OP got it resolved by himself.


这篇关于在ASP.NET中的页面重定向的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆