Reference it as obj[myID], where "obj" is the object where the myID instance exists. If obj is the current object, use this[myID].
--- In flexcoders@yahoogroups.com, "Nate Pearson" <[EMAIL PROTECTED]> wrote: > > Yes, but if "item1" gets passed back as a string in my result event I > don't know how to reference it. > I.E. > > var myID:String = String(event.result[0]) > > Now how do I reference the RTE with that ID? > > > --- In flexcoders@yahoogroups.com, "Doug Lowder" <douglowder@> wrote: > > > > Hi Nate, > > > > The id property of mxml components just tells the compiler what to name > > the instance variable when it generates the actionscript code. So, > > your mxml object with id "item1" can be referenced in script as simply > > item1: > > > > item1.htmlText = "TEST"; > > > > Search the archives for more info; there are some really good posts on > > this topic direct from the Adobe folks. > > > > > > --- In flexcoders@yahoogroups.com, "Nate Pearson" <napearson99@> > > wrote: > > > > > > I am calling a webservice to get text for an item (RichTextEditor) that > > > I am adding dynamically. > > > > > > If i set the ID of the rte to "item1" how do I reference that in my > > > webservice handler? I have the string pass through so that the > > > handler knows that the ID should be item1. > > > > > > I've tried: > > > RichTextEditor("item1").htmlText = "TEST" > > > > > > and > > > > > > RichTextEditor(this.getChildByName("item1")).htmlText = "TEST" > > > > > > but neither work. Any help is greatly appreciated. > > > > > >