How to gather the caller page information?

Discussion in 'ASP .Net' started by ABC, Jan 13, 2006.

  1. ABC

    ABC Guest

    How to gather the caller page information? I want to check the enter from
    when entering the onload event of the page. Which properties or functions
    have that information?
     
    ABC, Jan 13, 2006
    #1
    1. Advertising

  2. ABC

    DavidG Guest

    Are you asking how to retrieve values when the client posts back the
    page, if so:

    1) Server controls are accessed using the object properties, so if my
    page has a textbox control called txtCustomerName I can access it in
    code with :

    if (Page.IsPostBack)
    {
    string customerName = txtCustomerName.Text;

    Label1.Text = customerName;
    }

    2) html controls you can use the Request object in code

    if (Page.IsPostBack)
    {
    string customerName =
    Request["txtCustomerName"].ToString();
    Label1.Text = customerName;
    }

    HTH

    -----------------------------------------
    David Gray
    ASP.NET/C# Developer/Architect (MCAD.NET)

    On Fri, 13 Jan 2006 10:23:09 +0800, "ABC" <> wrote:

    >How to gather the caller page information? I want to check the enter from
    >when entering the onload event of the page. Which properties or functions
    >have that information?
    >
     
    DavidG, Jan 13, 2006
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Klaus Neuner
    Replies:
    14
    Views:
    454
    Paul McGuire
    Dec 15, 2004
  2. Florencio Cano
    Replies:
    1
    Views:
    322
  3. Jan Kechel
    Replies:
    1
    Views:
    95
    Roger Pack
    Aug 17, 2010
  4. Mark
    Replies:
    2
    Views:
    397
  5. Brady
    Replies:
    2
    Views:
    129
    DJ Stunks
    Jul 15, 2006
Loading...

Share This Page