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

RadWindow Progress Loading

1 Answer 66 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Muhammad Imran
Top achievements
Rank 1
Muhammad Imran asked on 28 Aug 2010, 06:33 PM
Hi

I m using to load RadWindow
ShowContentDuringLoad="true"
Progress image not showing but showing if ="false" i want to show progress with "true"
can i do it?

thx

1 Answer, 1 is accepted

Sort by
0
gim.net
Top achievements
Rank 1
answered on 12 Dec 2013, 03:35 PM
you can do it by placing your own RadAjaxLoadingPanel on the page, give it a style like this one:

  .LoadingPanel
        {
            position: absolute;
            z-index: 99999;
}
put a div around your whole page and name it "PageDiv"
than you make two JS functions to turn it on and off:

 function showTLoadingPanel() {
            var currentLoadingPanel = $find("<%= panel.ClientID %>");
            var currentUpdatedControl = "PageDiv
            currentLoadingPanel.show(currentUpdatedControl);
        }

        function hideTLoadingPanel() {
            var currentLoadingPanel = $find("<%= panel.ClientID %>");
            var currentUpdatedControl = "PageDiv"
            currentLoadingPanel.hide(currentUpdatedControl);
        }

Add a handler for the form submit to turn the panel on and a call to turn the panel off on load.
  function submit_handler() {

            try {showTLoadingPanel(); } catch (ex) { }

            return true;
        }

        try {hideTLoadingPanel(); } catch (ex) { }

Last step - add the handler call on the form submit event:
 <form id="form1" runat="server"   onsubmit="javascript:return submit_handler();">

that's it - every postback will expose your loading panel and it will turn off after the page loaded.
Tags
General Discussions
Asked by
Muhammad Imran
Top achievements
Rank 1
Answers by
gim.net
Top achievements
Rank 1
Share this question
or