I'm trying to use Ext.each.
It throughs an error: this.el.dom has no properties
Here's how I call it:
var ds = ctxtObj.select("input.date", true);//.on("click", this.showDate);
Ext.each(ds, this.attachDate, this);
attachDate looks like this:
attachDate : function(item, index, allItems){
var d = new Ext.form.DateField({
target: item,
value: '02/28/2007',
format: 'm/d/Y'});
},
I tried casting 'item' in the function to an element, but that didn't change it.
Any idea what I'm doing wrong?
Thanks...martin
#2
03-04-2007, 12:59 AM
|
|
Each operates on an array. A composite element is not an array. However, the CompositeElement class has it's own each method to make this easy.
var ds = ctxtObj.select("input.date", true);//.on("click", this.showDate);
//Ext.each(ds, this.attachDate, this);
ds.each(this.attachDate, this);
However, you can use it's "elements" property (array) with each.
|
分享到:
相关推荐
If you use constants in your value, and these constants belong to a ; dynamically loaded extension (either a PHP extension or a Zend extension), ; you may only use these constants *after* the line ...
You MUST use the INSTALL program to install Turbo C++. The files on the distribution disks are all archived and have to be properly assembled. You cannot do this by hand! IMPORTANT! If you want...
You MUST use the INSTALL program to install Turbo C++. The files on the distribution disks are all archived and have to be properly assembled. You cannot do this by hand! IMPORTANT! If you want...
WELCOME TO TURBO C 2.0 ---------------------- This README file contains important, last minute information about Turbo C 2.0. The HELPME!.DOC file on the COMMAND LINE/UTILITIES disk also answers ...
WELCOME TO TURBO C 2.01 ----------------------- This README file contains important, last minute information about Turbo C 2.01. The HELPME!.DOC file on the COMPILER/UTILITIES disk also answers many...
How to use ----------- One-shot pack & unpack ^^^^^^^^^^^^^^^^^^^^^^ Use ``packb`` for packing and ``unpackb`` for unpacking. msgpack provides ``dumps`` and ``loads`` as alias for compatibility with...
- Added an IRC log to explain how to use it (Greetings to LaBBa) - Tracers - Error codes updated for the Tracers Level2 and 3 - Plugin Tracer - Redesigned interface for good reasons (See <Plugin....
- **Using a Swap Space**: Describes how to configure and use swap space. - **Sharing Swap Spaces with Other Operating Systems**: Discusses sharing swap space across multiple operating systems. - **...
these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the...
- **Permissions and Ownership**: Detailed explanation of file permissions and ownership, including how to change them using commands like `chmod` and `chown`. #### Part V - Applications **Chapter 13...
protocols will help you understand how to use the JavaMail API. While the API is designed to be protocol agnostic, you can't overcome the limitations of the underlying protocols. If a capability isn...
In this part I will show you how to use the .htaccess file to implement some of these. 在上一部分,我已经简单介绍了.htaccess以及它的一些有用功能,在这一部分,我将向你演示如何使用.htaccess文档去...