Asp

Discussion in 'ASP .Net' started by Ntumu Siwedi, Jun 24, 2010.

  1. Ntumu Siwedi

    Ntumu Siwedi Guest

    how do i include text in this line below????
    something like Message "succesful" or " Failed "


    <uc1:ucPageMessage ID="ucPageMessageDisplay" runat="server" />


    in the button

    public void btnOk_Click(object sender, EventArgs e)

    {
    if (StagingUnitStandards.Import(visionUnitStandardNr) == 0)
    {
    Response.Write("Import Successfull");
    }
    else
    {
    Response.Write("Import Failed");
    }
    }

    *** Sent via Developersdex http://www.developersdex.com ***
     
    Ntumu Siwedi, Jun 24, 2010
    #1
    1. Advertising

  2. Ntumu Siwedi

    Mr. Arnold Guest

    Ntumu Siwedi wrote:
    > how do i include text in this line below????
    > something like Message "succesful" or " Failed "
    >
    >
    > <uc1:ucPageMessage ID="ucPageMessageDisplay" runat="server" />
    >
    >
    > in the button
    >
    > public void btnOk_Click(object sender, EventArgs e)
    >
    > {
    > if (StagingUnitStandards.Import(visionUnitStandardNr) == 0)
    > {
    > Response.Write("Import Successfull");
    > }
    > else
    > {
    > Response.Write("Import Failed");
    > }
    > }


    You can place a Label on the form and use the Label.Text to display a
    message to the user, clearing the Label.Text as needed.

    Or you can go to the HTML Button on the ASP.NET page, using the button's
    client-side HTML click-event and tie the click-event to a JavaScript
    function that has an Alert("some text"), which will pop-up a messagebox
    to the user.
     
    Mr. Arnold, Jun 24, 2010
    #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. Ben
    Replies:
    3
    Views:
    1,154
  2. Andrea Raimondi
    Replies:
    1
    Views:
    482
  3. R.A.M.
    Replies:
    1
    Views:
    3,241
    =?Utf-8?B?Y2xpY2tvbg==?=
    Mar 29, 2006
  4. Daves
    Replies:
    2
    Views:
    739
    Patrice
    May 31, 2006
  5. David A. Beck
    Replies:
    10
    Views:
    1,037
    Scott McNair
    Apr 13, 2004
Loading...

Share This Page