Click here to Skip to main content
15,905,967 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

web application,
I've two Textboxes(text1 and text2) and one button (btn_save)contols.And i've put this conrols under UpdatedPanel control.My question is as soon as click on btn_save button popup should come up and i've used following code to show confirmation:

ClientScript.RegisterStartupScript(this.GetType(), "Mess", "<script> alert( ' Entered Data Saved Successfully')</script>", false);


But popup is not comming up if i use updatedpanel control, or else its working fine.please reply with an example.
Posted
Updated 15-Jun-11 2:11am
v2
Comments
Prasad CM 15-Jun-11 8:42am    
R U Using Modal PopUp Control Or Just Simple Alert Msg ?

Write this Code it will work

blMsg.Text = "Course Name already Exists..."

ScriptManager.RegisterStartupScript(Me.Page, Me.GetType, "ClientScript", "alert('" & lblMsg.Text & "');", True)
 
Share this answer
 
Comments
bharat peggem 13-Apr-13 1:54am    
ya its working

bharath

thank you
try to use javascript


on button events

write 'onclientclick='fun1()'




function fun1()
{
alert('saved successfully')
}
 
Share this answer
 
Instead of ClientScript.RegisterStartupScript Use ScriptManager.RegisterStartupScript
 
Share this answer
 
v4
Comments
ambarishtv 15-Jun-11 8:34am    
my +5

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900