I suggest you to use LinkButton.
Page1.aspx
<div>
<input type="text" id="txt1" runat="server" />
<asp:LinkButton ID="LinkButton1" runat="server" onclick="LinkButton1_Click">Search</asp:LinkButton>
</div>
protected void LinkButton1_Click(object sender, EventArgs e)
{
if (!String.IsNullOrEmpty(txt1.Value))
{
Session["myvalue"] = txt1.value;
Response.Redirect("Page2.aspx");
}
}
On Page2.aspx
protected void Page_Load(object sender, EventArgs e)
{
object mypass;
mypass = Session["myvalue"];
}
may help