View Single Post
  #1 (permalink)  
Old February 1st, 2008, 07:23 AM
Harjinder Harjinder is offline
Authorized User
 
Join Date: Jan 2008
Location: Chandigarh, Punjab, India.
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Harjinder
Default Master Page and Content Page with Java script

Hi Everyone


I have the problem i want to read value from content page namely
default2.aspx to default3.aspx

please help

Default2.aspx Page Coding
Code:
<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" Title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<script language="javascript">
function abc()
{
  var e = document.getElementById('TextBox1');
  window.open("default3.aspx?ab= " + e.value.toString());
}
</script>


 Default3.aspx Coding

 protected void Page_Load(object sender, EventArgs e)
    {
        if (Request.QueryString["ab"] == null)
            Response.Write("Sorry");
        else
            Response.Write(Request.QueryString["ab"].ToString());
    }

Please Help on i m very eager

    <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
    <asp:Label ID="Label2" runat="server" Text="Label"></asp:Label>
    <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
    <asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>
    <asp:Button ID="Button1" runat="server" Text="Button" />
</asp:Content>
harjinder
__________________
Harjinder