I thank you for the response, John. I am new to Sencha and am not very experienced.
Yes, I tried yesterday entering the code via the maxValue - Object config property within Sencha for the Ext.form.field.Date control.
Yesterday I tried doing an afterrender event on this Ext.form.field.Date control to use setMaxValue but could not figure out how to do it and get it to work. For example, I tried entering into the afterrender event on the Ext.form.field.Date control the following code that does not seem to error in browser but that does not disable the future dates (and also causes the width of the text area of the Ext.form.field.Date to decrease despite the maxWidth 250 and labelWidth 140):
setMaxValue(Ext.util.Format.date(new Date(), 'm/d/Y'));
Also I tried the following in the afterrender of the Ext.form.field.Date control but the future dates were not disabled:
me.setMaxValue(Ext.util.Format.date(new Date(), 'm/d/Y'));
margin: '-20 0 0 160',
fieldLabel: 'Slaughter or Bone Date',
Just now I removed that afterrender on the Ext.form.field.Date since that approach did not seem to disable the future dates and since also the width of the textarea of the Ext.form.field.Date control decreases so that you do not see the full date, so that you do not see the year part of the date, when you select a date from the picker..
I already have an afterrender on the form (on the Ext.form.Panel) to set focus on a particular textfield.
title: 'Combo Box User Input',
So just now I added a line of code to the form's afterrender:
It worked! The future dates ARE disabled AND the width of the text area of the Ext.form.field.Date is not decreased!
Ext.getCmp('paramSlaughterOrBoneDate').setMaxValue(Ext.util.Format.date(new Date(), 'm/d/Y'));
Thanks very much to you, John. I really appreciate the help. I'll look to see if there is some way in which I can designate that you provided the answer or give you points or whatever.
I wonder why the afterrender event on the Ext.form.field.Date did not disable the future dates whereas the afterrender on the whole form does disable the future dates. Also, I wonder why using the setMaxValue(Ext.util.Format.date(new Date(), 'm/d/Y')) in the Ext.form.field.Date's maxValue - Object via the Config property pane does not work. Do you have any idea why I cannot use the maxValue config property via the Config pane does not work and why the afterrender of the Ext.form.field.Date does not work?
Thanks again as I very much appreciate the help. Using the form's afterrender and the code that I provided above DOES WORK and now the Ext.form.field.Date control will have always the future dates disabled.
Hviezdoslav 18-JAN-2013 Friday