Thx Tracy! That worked. You rock! -Steve
--- In [email protected], "Tracy Spratt" <[EMAIL PROTECTED]> wrote: > I neglected to pass the reference into the class: > <ApplyBillingCycle id="abs" myParent="{this}" ../> > Tracy > > -----Original Message----- > From: Tracy Spratt [mailto:[EMAIL PROTECTED] > Sent: Wednesday, April 13, 2005 4:15 PM > To: [email protected] > Subject: RE: [flexcoders] howto call titlewindow vars in class imported > by titlewindow? > > > If I have misunderstood you, just ignore me, but here are a few > comments: > > Why are you extending ccardWindow in the applyBillingCycle class? Just > create a custom class, pass a reference to the title window into it: > > class ApplyBillingCycle { > public var myParent:ccardWindow > public function cycleNow(){ > //my giant case/switch code > Var localVar:String = myParent.myVariable > } > > Instantiate the class in ccardWindow: > <ApplyBillingCycle id="abs" ../> > > Call cycleNow: > abs.cycleNow().... > > Tracy > > -----Original Message----- > From: stevenkeys2003 [mailto:[EMAIL PROTECTED] > Sent: Wednesday, April 13, 2005 3:25 PM > To: [email protected] > Subject: [flexcoders] howto call titlewindow vars in class imported by > titlewindow? > > > > All, > I recently hit the 32k limit on one of my .as files. This particular > .as is being included inline within a TitleWindow. There's one > particular function within it which has a very long case/switch, which > I know is causing the 32k limit to be exceeded. > > I'm now trying to break this one function out as a class. The class is > being called by the TitleWindow successfully, but any TitleWindow > ids/vars I try to reference just aren't appearing. > > My setup: > > main titlewindow: ccardWindow.mxml > includes parent .as file inline: > <mx:Script source="ccardWindowProcess.as"/> > > ccardWindowProcess.as imports new class: > > import applyBillingCycle; > > class file code: > > class applyBillingCycle extends ccardWindow { > > public function cycleNow(){ > my giant case/switch code > } > > ccardWindow.mxml (the titlewindow) calls the class method via: > applyBillingCycle.cycleNow() embedded in a change event for a comboBox. > > Now in class method cycleNow, I'm referencing ids of titlewindow: > ccardWindow.mxml and vars of ccardWindowProcess.as .. to no avail. No > errors occuring, i'm just not sure I'm referencing those variables > properly, and/or not extending what I need to be. When importing class > from titleWindow how do you reference variables of within class? > > > > > > > > > Yahoo! Groups Links > > > > > > > > > > > > > Yahoo! Groups Links Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/

