Search content within the blog

Monday, November 17, 2008

Use Of Literal to Display Alerts from code-behind

Literal ltAlertMsg = new Literal();
ltAlertMsg.Mode = LiteralMode.Transform;
this.Controls.Add(ltAlertMsg);
ltAlertMsg.Text =@"<script>alert(""Test Message ."");</script>";

No comments:

Post a Comment