Hi indradeo,
Please refer below Sample.
HTML
Default
<table>
<tr><td>Number:<asp:TextBox ID="txtNumber" runat="server"></asp:TextBox></td></tr>
<tr><td><asp:Button ID="btnSave" Text="Send" runat="server" OnClick="Save"/></td></tr>
</table>
<asp:Label ID="lblMessege" runat="server"></asp:Label>
Home
<asp:Label ID="lblNumber" runat="server"></asp:Label>
Code
C#
Default
protected void Save(object sender, EventArgs e)
{
int number = int.Parse(txtNumber.Text);
if (number > 40000000 && number <=150000000)
{
lblMessage.Text = "Services";
Response.Redirect("Home.aspx?Message=Services");
}
else if(number > 150000000)
{
lblMessage.Text = "Purches";
Response.Redirect("Home.aspx?Message=Purches");
}
}
Home
protected void Page_Load(object sender, EventArgs e)
{
lblNumber.Text = Request.QueryString["Message"];
}
VB.Net
Default
Protected Sub Save(ByVal sender As Object, ByVal e As EventArgs)
Dim number As Integer = Integer.Parse(txtNumber.Text)
If number > 40000000 AndAlso number <= 150000000 Then
lblMessage.Text = "Services"
Response.Redirect("Home.aspx?Message=Services")
ElseIf number > 150000000 Then
lblMessage.Text = "Purches"
Response.Redirect("Home.aspx?Message=Purches")
End If
End Sub
Home
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
lblNumber.Text = Request.QueryString("Message")
End Sub
Screenshort