Thursday, January 13, 2011

asp.net ajaxtoolkit modalpopupextender open server side and cleint Side

Following code will help for how to open ajaxtoolkit modalpopupextender

how it can open via server side code (c#) or cleient Side code

javascript
==========
var launch = false;
function launchModal() {
launch = true;
}

function pageLoad() {
if (launch) {
$find("modalpopupextender client id need to pass here").show();
}
}

Client Side
============

OnClientClick="launchModal()"

serverside:=
============

Following code need to write in any button control click event

ClientScript.RegisterStartupScript(this.GetType(), "key", "launchModal();", true);

No comments: