从选项卡控制器重定向到新页面 [英] redirecting to new page from tab controller

查看:67
本文介绍了从选项卡控制器重定向到新页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在页面中使用制表符控制器,在此页面中我将数据保存到数据库之后我需要将消息显示在另一页面中。为此,我完成如下





//标签控制器页面

Response.Redirect(CustomerEdit。 aspx?Name =+ TxtCustomerName.Text);







//在另一页

if(Request.QueryString [Name]!= null)

{

string CustomerName = Request.QueryString [Name]。ToString ();

LblMsg.Text =客户名++详情已成功添加。;

}



但是我能够收到消息,它没有重定向到另一个页面?

I'm using tab controller in a page, In this page I'm saving the data to database after that i need the message to be displayed in another page. For this i done as below


//tab controller page
Response.Redirect("CustomerEdit.aspx?Name="+TxtCustomerName.Text);



//In another page
if (Request.QueryString["Name"] != null)
{
string CustomerName = Request.QueryString["Name"].ToString();
LblMsg.Text = CustomerName + " " + "Details Added Successfully.";
}

But I'm able to get the message ,it is not redirecting to another page ?

推荐答案

试试这个。



try this.

Dim url As String = "~/SomeDirectory/SomePage.aspx"
Response.Redirect(url.Replace("~"c, Request.ApplicationPath))





或类似这样



Response.Redirect(./ hello);



or like this

Response.Redirect("./hello");


这篇关于从选项卡控制器重定向到新页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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