Asp

N

Ntumu Siwedi

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");
}
}
 
M

Mr. Arnold

Ntumu said:
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.
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top