PDA

View Full Version : LoadMask on Form



dpaquin
3 Nov 2011, 11:24 AM
What is the proper way to add a load mask to a form, which would trigger when the form's Load() method is called (when populating the form fields from a URL)?

mitchellsimoens
4 Nov 2011, 5:21 AM
If you do:


form.getForm.load();

It should mask the form with a mask.

dpaquin
4 Nov 2011, 6:47 AM
Hmm that is what I'm doing, more or less (sorry, should have posted the code along with my question):


Ext.getCmp("areaSetupTab").getForm().load({
url: "/getarea",
params: {
area: area
},
success: function(form, action) {
loadDatapoints({
area: area,
type: "Area"
});
},
failure: function(form, action) {
Ext.Msg.alert("Notice", action.result.errorMessage);
}
});

When the form load there is no mask. Although for a grid inside this form, a mask does automatically appear when calling load() for its store (the loadDatapoints() function)... This is with ExtJS 4.0.7.

dpaquin
7 Nov 2011, 11:10 AM
Any ideas?

mitchellsimoens
7 Nov 2011, 11:15 AM
LoadMask may be being shared and the grid is last one to request it so it gets the mask.