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

RadWindow alert

3 Answers 125 Views
Window
This is a migrated thread and some comments may be shown as answers.
jo
Top achievements
Rank 1
jo asked on 15 Sep 2008, 09:42 PM
I'm using RadWindow alert to show a message when user clicks on a link in Rad Grid.

if

(e.CommandName.Equals("Reset"))

{

ScriptManager

.RegisterStartupScript(Page, typeof(Page), "RadAlert",

"Sys.Application.add_load(function(){radalert(' password reset');});", true);

}
This alert is working; but
The alert is now stuck in the response scripts and will be shown every time the ajax panel reloaded. Is there a way to clear it once it has been shown?

3 Answers, 1 is accepted

Sort by
0
Georgi Tunev
Telerik team
answered on 16 Sep 2008, 11:42 AM
Hello jo,

You need to remove the script from the add_load() handler after that. For a possible approach, you can check the comments in the following KB article:
http://www.telerik.com/support/kb/article/b454K-gtd-b454T-cec-b454c-cec.aspx



All the best,
Georgi Tunev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
jo
Top achievements
Rank 1
answered on 16 Sep 2008, 04:39 PM
I tried this-
RadAjaxManager1.ResponseScripts.Add("(function(){var f = function(){radalert('Welcome to RadWindow Prometheus!', 330, 210);Sys.Application.remove_load(f);};Sys.Application.add_load(f);})()");

It's not showing on first call back.
It's supposed to show on first call back and dont show on any further call backs.
0
Georgi Tunev
Telerik team
answered on 17 Sep 2008, 01:37 PM
Hello jo,

Please open a new support ticket and send me your implementation so I can check it. Just make sure that the project can be run locally and attach it to the ticket - I will check it and get back to you.



All the best,
Georgi Tunev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Window
Asked by
jo
Top achievements
Rank 1
Answers by
Georgi Tunev
Telerik team
jo
Top achievements
Rank 1
Share this question
or