Hi indradeo,
Use Session for sending TextBox value and retrive that in otherpage and set in HiddenField.
Refer to below sample.
HTML
Default
<table>
<tr><td> Name:<asp:TextBox ID="txtName" runat="server"></asp:TextBox></td></tr>
<tr><td><asp:Button ID="btnSubmit" runat="server" Text="Submit" OnClick="Submit"/></td></tr>
</table>
Home
<asp:HiddenField ID="hfName" runat="server" />
<asp:Label ID="lblName" runat="server" />
Namespace
C#
using System.Data;
VB.Net
Imports System.Data
Code
C#
Default
protected void Submit(object sender, EventArgs e)
{
Session["Name"] = txtName.Text;
Response.Redirect("~/Home.aspx");
}
Home
protected void Page_Load(object sender, EventArgs e)
{
if (!this.IsPostBack)
{
string name = Session["Name"].ToString();
hfName.Value = name;
lblName.Text = hfName.Value;
}
}
VB.Net
Default
Protected Sub Submit(ByVal sender As Object, ByVal e As EventArgs)
Session("Name") = txtName.Text
Response.Redirect("~/Home.aspx")
End Sub
Home
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs) handles Me.Load
If Not Me.IsPostBack Then
Dim name As String = Session("Name").ToString()
hfName.Value = name
lblName.Text = hfName.Value
End If
End Sub
Screenshort