dont' want to execute events on the load

January 05th, 2009 edit

hello,

i'm a new user of extjs and scuse for my poor english (i'm french !).

My question : how to not execute events (like checkbox checked) on the load of my page ?

I would like to display a form panel with a checkbox that is checked (in the code) by default but on the load of the page the listener execute the function (because the listener see that the checkbox is checked).
How to not execute listener if a checkbox is checked ?

here is the javascript code with my problem in red text:


var gridForm = new Ext.FormPanel({
//url : this.url_rappel,//correspond a action d'un form
id : 'form_rappel',
frame : false,//gestion d'un titre avec encadrement
//renderTo : grid4,
title : '',//titre du formulaire
width : 800,//longueur
//height : 200,//hauteur
labelWidth : 40,//largeur du label
labelAlign : 'right',//alignement du label
labelPad: 10,
//layout: 'column', // Specifies that the items will now be arranged in columns
defaults: {//valeur des param par defaut pour les objets enfants
bodyStyle:'padding:2px 2px 0; text-align: right'
//border:none;
//width: 230,
//msgTarget: 'side'
},
layoutConfig: {
labelSeparator: ''
},
defaultType: 'textfield',//type de cellule par defaut des objets enfants
baseCls: 'x-plain',//type de form
headerAsText: true,//????
method: 'POST',//methode du form
items: [
{
columnWidth : 0.5,//taille de la colonne
xtype : 'datefield',//type d'input
fieldLabel : 'Debut',//nom du lable
value : new Date(),//valeur par defaut
name : 'rappel_cal',//name de l'objet
format : 'd/m/Y',//format de date
id : 'rappel_cal',//id de l'objet
allowBlank : true,//false : obligatoire / true : optionnel
listeners : {
//fn: this.updateColors,
//activate,valid,scope,check,render,loadexception,lo ad,resize,show,afteredit
valid: function(datefield){
//alert('coucou2');
//fct_filtre_date(datefield);
}
,scope: this
}
},{
columnWidth : 0.5,//taille de la colonne
xtype : 'checkbox',//type d'input
fieldLabel : 'Rappel',//nom du lable
defaults : {bodyStyle: 'text-align: right'},//les valeurs par defauts
inputValue :"Y",//valeur de la checkbox
//checkboxToggle:true,
name : 'filtre_date',//name de l'objet
id : 'filtre_date',//id de l'objet
allowBlank : true,//false : obligatoire / true : optionnel

listeners : {
check : function(checkbox, checked) {//fonction a appliquer
//fct_filtre_rappel(checkbox, checked);
}
,scope: this
},
checked : true,//checkbox cochee

}
]
,buttons: [{
text : 'Search',
handler : function(){
fct_submit_form();
donnees_rappel.reload();
grid4.doLayout();
//pnPosGrid.enable();
}
}]
});



thanks for your repply




#If you have any other info about this subject , Please add it free.#
Your name:
E-mail:
Telphone:

Your comments:


If you have any other info about dont' want to execute events on the load , Please add it free.