how can we use java script message alert with asp.net with
useing vb.net coding show full process with its coading

Answer Posted / me

To work with javascript in ASP.NET, the best way to do it,
is using the Page.ClientScript object at some point.

For instance, if you want to show an alert box when the
page is finished loading, use this:

string javascript = "alert('Finished loading!');"
Page.ClientScript.RegisterStartupScript(typeof
(string), "key", javascript,true);

The ClientScript object has other methods, like
RegisterClientScriptBlock, RegisterClientScriptInclude,
RegisterExpandoAttribute and so on, which all allow you to
add javascript to the page in different ways.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What Does JavaScript Void(0) Mean?

522


What and where are the best javascript resources on the web?

482


What is Number object in JavaScript?

557


Is there any class in javascript?

489


What does break and continue statements do in javascript?

521






What is the similarity between the 1st and 2nd statement?

504


How to detect the operating system on the client machine?

488


What are the string methods?

466


What is the difference between let and var?

554


How to validate a form in javascript?

484


What are the main functions performed by javascript statements?

506


What is new keyword in javascript?

475


How do you change the style/class on any element?

516


Is javascript open source?

443


what is the function of public class main ?

1516