Adds Client-side Confirmation Button to a Button Control
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
Me.Button1.Attributes.Add("onclick", "return confirm('Are you sure?');")
End If
End Sub
Adds Pop Up Window to Button Control
Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) _
Handles Button1.Click
Dim popupScript As String = ""
ClientScript.RegisterStartupScript(GetType(String), "PopupScript", popupScript)
End Sub
No comments:
Post a Comment