How to add javascript in Asp.Net code behind?

On_PageLoad evnt,
add the below code..
button1.Attributes.Add("OnClick", "javascript:alert('our message')");

Comments

  1. You have restriction on conditional alert, for that you can click on the next blog..

    ReplyDelete

Post a Comment

Popular posts from this blog

Performance Optimization in Sitecore

Azure Event Grid Sample code

Managing Microservice Security at Various Levels