flex-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Evyatar Ben Halevi-Arbib <evyata...@gmail.com>
Subject Re: Different properties names at runtime
Date Wed, 13 May 2015 20:58:56 GMT
You can standardize the data before passing it to the item-renderer.
For example, run a for-each loop and if the object got a "non-standard"
property populated, assign it as the value of the standard property.
That way the renderer code would be more simple.

Regards,
Evyatar

On Wed, May 13, 2015 at 11:00 PM, mark goldin <markzolotoy@gmail.com> wrote:

> Yes, that is what I am doing. Thought it could be something more robust
> than that.
>
> On Wed, May 13, 2015 at 2:55 PM, OmPrakash Muppirala <bigosmallm@gmail.com
> >
> wrote:
>
> > Look up Object.hasOwnProperty()
> >
> >
> >
> http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/Object.html#hasOwnProperty()
> >
> > Thanks,
> > Om
> >
> > On Wed, May 13, 2015 at 12:52 PM, mark goldin <markzolotoy@gmail.com>
> > wrote:
> >
> > > I have an item renderer whose data might be something like this:
> > >
> > > data.countryName or
> > >
> > > data.CountryName
> > >
> > > In order to make it work I have to validate data.countryName and if it
> > > exists use it or go with data.CountryName.
> > >
> > > Is there more sophisticated way of compensating for lousy server code?
> > >
> > > Thanks
> > >
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message