Forum /
Ext JS 2.x - Unsupported /
Ext 2.x: Help & Discussion /
Masking
Masking
Does anyone know on how to apply a page mask during page loading once a submit button is clicked?
I have 2 grids on the page and I want to apply page masking until loading of the two tables are completed.
Thank you.
Sencha - Community Support Team
Ext.getBody().mask('Saving data...', 'x-mask-loading');
Thanks for your reply.
What I mean is, if i put this code in the Submit Button handler:
Ext.getBody().mask('Loading..');
PopulateGrids();
Ext.getBody().unmask();
The loading message doesn't appear because extjs is asynchronous. It executes the unmask() statement even before the PopulateGrids() finished its execution.
I hope someone can help me with this.
Thanks again.
Sencha - Community Support Team
well, unmask after the stuff is loaded via event handlers or callbacks.
Sencha - Community Support Team
Look at the docs for the 'load' event of the datastore.
Thanks again for your reply.
Yes, I have tried that. But as what I've mentioned before in post, I have two grids. Is there a way where I can check that BOTH grids have completed loading? After the've loaded successfully that's when I'll do the unmasking.
I really appreciate your continous reply on this.
Thanks JGarcia! I'll just put the unmask on one of the datastore for now since both of them almost finished loading at the same time!
I really appreciate your help!!
Sencha is used by over two million developers. Join the community, wherever you’d like that community to be
or Join Us