This is a migrated thread and some comments may be shown as answers.

RadAjaxManager.Alert() title on message?

1 Answer 193 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Andrew Whiteside
Top achievements
Rank 1
Andrew Whiteside asked on 22 Oct 2009, 09:13 AM
Hi

The alert method of the RadAjaxManager is a very quick and easy way to displays client side message from server side code, which is great.

Is there are way to modify the alert to specify the "title" of the alert box that pops up?

My picture should explain the problem better...

Cheers

Andrew

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 22 Oct 2009, 10:16 AM
Hi Andrew,

One suggestion is calling radlalert from code behind which allows additional parameters like dialog width and height and a title alert.
C#:
 
protected void Button1_Click(object sender, EventArgs e) 
    string radalertscript = "<script language='javascript'>function f(){radalert('Delete Failed <b>Prometheus</b>!', 330, 210,'My Title'); Sys.Application.remove_load(f);}; Sys.Application.add_load(f);</script>"
    Page.ClientScript.RegisterStartupScript(this.GetType(), "radalert", radalertscript); 
[Note: Also add RadWindowManager on page]

You can checkout the KB Article for more information on Calling radalert from codebehind

-Shinu.
Tags
Ajax
Asked by
Andrew Whiteside
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or