Show Loading Panel when Save form

Hi,

How can I show loading panel when I click “Save” button inside form? For grid, I can add modalbox inside onXLS event . And hide it inside onXLE event. So, it will show loading panel when grid is loading.

How can I do it when user click on button inside form? I need to show loading panel because sometimes the process is very long and there is no hint the form is still processing. When I tried to go to other page, then whole program not working already.

Hi
You can try to do it based on this sample locally:
dhtmlx.com/docs/products/dhtmlxF … _save.html
You need just to add “onBeforeSave” and “onAfterSave” event handlers after loading formdata:

myForm.attachEvent("onBeforeSave", function (id, values){ // document.getElementById("test1").innerHTML = "Start saving"; box = dhtmlx.modalbox({ text: "Loading, Please Wait...", width: "300px" }); return true; }); myForm.attachEvent("onAfterSave", function (id, xml){ // document.getElementById("test2").innerHTML = "End saving"; dhtmlx.modalbox.hide(box); });
Commented lines are just for show progress (in this demo saving command are quite fast, so these objects are like logs - see picture below)

Hi,

Thank you for your reply. There is one more problem. I have master page and child page. Loading panel only show for child page and I can still click links on master page. How can I make it show for whole page?

Thanks in advance.

In this case you can use our layout to show loading status to the sell or the whole layout. Also you can attach URLs in layout cells
dhtmlx.com/docs/products/dhtmlxL … gress.html
Plus you can attach there form directly:
dhtmlx.com/docs/products/dhtmlxL … _form.html

Hi Darya,

Thank you so much for your support. Now I have another problem. The loading panel didn’t show when I tried to save the form with grid inside. The page just hang there, when I click the save button. Below is the same code that I tried.

HTML

.CS

Any way to show loading panel? Thank you.

Hi

Could you please provide us complete demo including all correspondnig js/css files?
Please also add information regarding current and expected behaviour.

Here is a small guide how to make a complete demo:
docs.dhtmlx.com/tutorials__auxil … pport.html

If you don’t want to share your demo here for any reasons - you can send it to support@dhtmlx.com, if so - please include link to this forum topic.

If you’re using PRO Edition please send your demo to support@dhtmlx.com

Hi Andrei,

I sent demo to support@dhtmlx.com .

I am hoping to hear from you soon.

Thank you.

Hi

We haven’t received it. You can try to upload it to you srever and send us link?

Dear Andrei,

Do you mean you didn’t receive my email at all? I sent to support@dhtmlx.com with the subject header “Show Loading Panel when Save form” . I uploaded to dropbox and sent the link again. I can’t place the link here because I am using pro version. Any other way to send the demo?

Thank you.