"use javascript"
-
iam having button(server control) once i clik it should excute java script function and server side code i need syntax plz
-
iam having button(server control) once i clik it should excute java script function and server side code i need syntax plz
write javascript function on "OnClick" event of button. once done with function return true, this will take page posted to server and server code will get executed.
Regards, Akhilesh Yadav
-
iam having button(server control) once i clik it should excute java script function and server side code i need syntax plz
hi, If you want to run the javascript and the server side code with a single button click event,then, you can do as follows: Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Response.Write("Postback: This is a server-side event ") End Sub function AlertHello(){ alert("Hello ..This is a client side Java script") } and add this line: So, when you click the Button, both the events are triggered... hope this helps..