[flexcoders] Re: Stupid question regarding sizing of mxml components

2008-07-12 Thread aduston1976
Hi Alex, Thank you for your reply. 

> then minHeight=0 should allow
> for scrollbars on the top.

That's what I would think too, but it is incorrect. I am using build
477 of Flex 3 SDK version 3.0.0. Here is my entire mxml application:


http://www.adobe.com/2006/mxml"; layout="absolute"
initialize="init()">




















The _outer VBox gets the scrollbars.

I am running on Flash Debug player 9,0,124,0 on Mozilla/5.0 (X11; U;
Linux i686; en-US; rv:1.9) Gecko/2008061015 Firefox/3.0.

Is this a bug? Any other suggestions to accomplish this?

Thank you again,
Adam

--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> If the bottom vbox's content is taller than the parent's 300 pixels, I
> don't think the top vbox will get scrollbars.  But if there's room for
> both the top to show some and the bottom, then minHeight=0 should allow
> for scrollbars on the top.
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of aduston1976
> Sent: Saturday, July 12, 2008 6:26 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Stupid question regarding sizing of mxml
> components
> 
>  
> 
> Hi dbronk, I need the top vbox to scroll but not the bottom one.
> Assuming that your sdk is sufficiently similar to mine, the solution
> you gave makes them both scroll. You can achieve this effect very
> easily without the Canvas components in your solution: just set
> height="50%" and minHeight="0" for both inner VBoxes. Unless I'm
> missing something in your reply, the original problem remains
> unsolved. Adam
> 
> --- In flexcoders@yahoogroups.com 
> , "dbronk"  wrote:
> >
> > Not sure why, seems like a bug. But if you wrap the inner vbox's in a
> > canvas it works.
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> >  
> > 
> > 
> > 
> > --- In flexcoders@yahoogroups.com
>  , "Paul Andrews"  wrote:
> > >
> > > Have you tried setting the verticalScrollPolicy?
> > > 
> > > If you want to refer to specific containers, give them an id so we
> > can be 
> > > sure which is being refered to.
> > > 
> > > This might be helpful: 
> > >
> >
> http://livedocs.adobe.com/flex/3/html/help.html?content=containers_intro
> _4.html
>  o_4.html> 
> > > 
> > > Paul
> > > - Original Message - 
> > > From: "aduston1976" 
> > > To:   >
> > > Sent: Sunday, July 13, 2008 12:17 AM
> > > Subject: [flexcoders] Stupid question regarding sizing of mxml
> > components
> > > 
> > > 
> > > > Hi, here is an easy one:
> > > >
> > > > 
> > > > 
> > > > ... lots of stuff ...
> > > > 
> > > > 
> > > > ... lots of stuff ...
> > > > 
> > > > 
> > > >
> > > > When lots of stuff is added, I want the top inner VBox to show
> > > > scrollbars, not the second. Any way to do this? Other than by
> setting
> > > > minHeight="0", which I've tried and which doesn't work?
> > > >
> > > > Here is a non-standard solution: I could change the outer VBox to
> a
> > > > VBox inheritor and override updateDisplayList, and then set
> > > > _first.height manually after calling super.updateDisplayList. Is
> this
> > > > totally wrong for any reason? Will I end up breaking Flex?
> > > >
> > > > Thanks,
> > > > Adam
> > > >
> > > >
> > > > 
> > > >
> > > > --
> > > > Flexcoders Mailing List
> > > > FAQ:
> http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
>  
> > > > Search Archives: 
> > > > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo
>  !
> Groups 
> > > > Links
> > > >
> > > >
> > > >
> > > >
> > >
> >
>




RE: [flexcoders] Re: Stupid question regarding sizing of mxml components

2008-07-12 Thread Alex Harui
If the bottom vbox's content is taller than the parent's 300 pixels, I
don't think the top vbox will get scrollbars.  But if there's room for
both the top to show some and the bottom, then minHeight=0 should allow
for scrollbars on the top.

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of aduston1976
Sent: Saturday, July 12, 2008 6:26 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Stupid question regarding sizing of mxml
components

 

Hi dbronk, I need the top vbox to scroll but not the bottom one.
Assuming that your sdk is sufficiently similar to mine, the solution
you gave makes them both scroll. You can achieve this effect very
easily without the Canvas components in your solution: just set
height="50%" and minHeight="0" for both inner VBoxes. Unless I'm
missing something in your reply, the original problem remains
unsolved. Adam

--- In flexcoders@yahoogroups.com 
, "dbronk" <[EMAIL PROTECTED]> wrote:
>
> Not sure why, seems like a bug. But if you wrap the inner vbox's in a
> canvas it works.
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
>  
> 
> 
> 
> --- In flexcoders@yahoogroups.com
 , "Paul Andrews"  wrote:
> >
> > Have you tried setting the verticalScrollPolicy?
> > 
> > If you want to refer to specific containers, give them an id so we
> can be 
> > sure which is being refered to.
> > 
> > This might be helpful: 
> >
>
http://livedocs.adobe.com/flex/3/html/help.html?content=containers_intro
_4.html
 
> > 
> > Paul
> > - Original Message - 
> > From: "aduston1976" 
> > To: mailto:flexcoders%40yahoogroups.com> >
> > Sent: Sunday, July 13, 2008 12:17 AM
> > Subject: [flexcoders] Stupid question regarding sizing of mxml
> components
> > 
> > 
> > > Hi, here is an easy one:
> > >
> > > 
> > > 
> > > ... lots of stuff ...
> > > 
> > > 
> > > ... lots of stuff ...
> > > 
> > > 
> > >
> > > When lots of stuff is added, I want the top inner VBox to show
> > > scrollbars, not the second. Any way to do this? Other than by
setting
> > > minHeight="0", which I've tried and which doesn't work?
> > >
> > > Here is a non-standard solution: I could change the outer VBox to
a
> > > VBox inheritor and override updateDisplayList, and then set
> > > _first.height manually after calling super.updateDisplayList. Is
this
> > > totally wrong for any reason? Will I end up breaking Flex?
> > >
> > > Thanks,
> > > Adam
> > >
> > >
> > > 
> > >
> > > --
> > > Flexcoders Mailing List
> > > FAQ:
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 
> > > Search Archives: 
> > > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo
 !
Groups 
> > > Links
> > >
> > >
> > >
> > >
> >
>

 



Re: [flexcoders] Re: Stupid question regarding sizing of mxml components

2008-07-12 Thread greg h
Hi Adam,

Does the following meet your criteria?

SWF here:
http://flexflashvideo.com/flexcoders/08/07/VBox_scrolls/

Source here:
http://flexflashvideo.com/flexcoders/08/07/VBox_scrolls/srcview/source/

Note that content is being clipped on _bottom since it has
verticalScrollPolicy="off"

So, content matters.

Nested containers must fit inside their parents.  So in cases where all of
the contents of the nested container can not be displayed, scroll bars are
generally desired.

btw ... I removed the minHeight="0".

hth,

g


[flexcoders] OT: team garmin- chipotle tour de france AIR news ticker

2008-07-12 Thread Paul Hastings
garmin's got a nice looking (based on their edge 705 bike GPS) AIR tour de 
france news ticker:

http://www8.garmin.com/teamgarmin/downloads.html

not sure how well it works as i'm a bit too early over here in the big mango 
but 
it does look nice.

btw the team's riders appear to be burrito-powered ;-)

http://www.velonews.com/article/79856/what-s-garmin-chipotle-on-anyway


Re: [flexcoders] dynamic move

2008-07-12 Thread [EMAIL PROTECTED]
Thanks, that was the problem. I'm still wondering why, if the error 
machine knew that the target was the wrong type, it couldn't tell me 
that. The error messages are almost completely worthless as far as I can 
see.

Rick Winscot wrote:
>
> So…. It looks like you have some issues with the line 
> moveSketch.target=”sketchBox”;  since the target is an Object and 
> you are setting it to a String… which is an Object but not the right 
> _/type/_ of Object. The compiler isn’t going to have a spaz but it 
> will surely cause a runtime error. Use moveSketch.target=sketchBox; 
> instead.
>
> Rick Winscot
>
> *From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
> *On Behalf Of [EMAIL PROTECTED]
> *Sent:* Saturday, July 12, 2008 8:38 PM
> *To:* flexcoders@yahoogroups.com
> *Subject:* [flexcoders] dynamic move
>
> In this code I'm dynamically creating an HBox, adding an image to it,
> adding the box to a Panel, and then creating a Move() to move the Hbox.
> It produces the error below, which says "value" is not a function. WHAT
> VALUE? Why doesn't it name the value ? What did I do wrong ?
> The error comes when I add the final line, moveSketch.play();
>
> var sketchBox:HBox = new HBox();
> var sketchImg:Image=new Image;
> sketchImg.source="Journeysketchsm.gif";
> sketchBox.addChild(sketchImg);
> thePanel.addChildAt(sketchBox,0);
>
> var moveSketch:Move = new Move();
> moveSketch.target="sketchBox";
> moveSketch.xTo=150;
> moveSketch.duration=3000;
> moveSketch.play();
>
>
> TypeError: Error #1006: value is not a function.
> at
> mx.effects::EffectInstance/play()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\EffectInstance.as:584]
> at
> mx.effects.effectClasses::MoveInstance/play()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\effectClasses\MoveInstance.as:230]
> at
> mx.effects::EffectInstance/startEffect()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\EffectInstance.as:569]
> at
> mx.effects::Effect/play()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Effect.as:930]
> at jbh/endEffectHandler()[K:\flex3\src\jbh.mxml:60]
> at jbh/___jbh_AnimateProperty1_effectEnd()[K:\flex3\src\jbh.mxml:9]
> at flash.events::EventDispatcher/dispatchEventFunction()
> at flash.events::EventDispatcher/dispatchEvent()
> at
> mx.effects::Effect/effectEndHandler()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Effect.as:1329]
> at flash.events::EventDispatcher/dispatchEventFunction()
> at flash.events::EventDispatcher/dispatchEvent()
> at
> mx.effects::EffectInstance/finishEffect()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\EffectInstance.as:651]
> at
> mx.effects::EffectInstance/finishRepeat()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\EffectInstance.as:690]
> at
> mx.effects.effectClasses::TweenEffectInstance/onTweenEnd()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\effectClasses\TweenEffectInstance.as:395]
> at
> mx.effects::Tween/endTween()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Tween.as:524]
> at
> mx.effects::Tween/http://www.adobe.com/2006/flex/mx/internal::doInterval 
> ()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Tween.as:565]
> at
> mx.effects::Tween$/timerHandler()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Tween.as:179]
> at flash.utils::Timer/_timerDispatch()
> at flash.utils::Timer/tick()
>
> 
> No virus found in this incoming message.
> Checked by AVG - http://www.avg.com 
> Version: 8.0.138 / Virus Database: 270.4.10/1549 - Release Date: 7/12/2008 
> 4:31 PM
>   




--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! 
Groups Links

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

<*> To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

<*> 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/



RE: [flexcoders] dynamic move

2008-07-12 Thread Rick Winscot
So.. It looks like you have some issues with the line
moveSketch.target="sketchBox";  since the target is an Object and you
are setting it to a String. which is an Object but not the right _type_ of
Object. The compiler isn't going to have a spaz but it will surely cause a
runtime error. Use moveSketch.target=sketchBox; instead.

 

Rick Winscot

 

 

 

 

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of [EMAIL PROTECTED]
Sent: Saturday, July 12, 2008 8:38 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] dynamic move

 

In this code I'm dynamically creating an HBox, adding an image to it, 
adding the box to a Panel, and then creating a Move() to move the Hbox.
It produces the error below, which says "value" is not a function. WHAT 
VALUE? Why doesn't it name the value ? What did I do wrong ?
The error comes when I add the final line, moveSketch.play();

var sketchBox:HBox = new HBox();
var sketchImg:Image=new Image;
sketchImg.source="Journeysketchsm.gif";
sketchBox.addChild(sketchImg);
thePanel.addChildAt(sketchBox,0);

var moveSketch:Move = new Move();
moveSketch.target="sketchBox";
moveSketch.xTo=150;
moveSketch.duration=3000;
moveSketch.play();


TypeError: Error #1006: value is not a function.
at 
mx.effects::EffectInstance/play()[E:\dev\3.0.x\frameworks\projects\framework
\src\mx\effects\EffectInstance.as:584]
at 
mx.effects.effectClasses::MoveInstance/play()[E:\dev\3.0.x\frameworks\projec
ts\framework\src\mx\effects\effectClasses\MoveInstance.as:230]
at 
mx.effects::EffectInstance/startEffect()[E:\dev\3.0.x\frameworks\projects\fr
amework\src\mx\effects\EffectInstance.as:569]
at 
mx.effects::Effect/play()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\
effects\Effect.as:930]
at jbh/endEffectHandler()[K:\flex3\src\jbh.mxml:60]
at jbh/___jbh_AnimateProperty1_effectEnd()[K:\flex3\src\jbh.mxml:9]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at 
mx.effects::Effect/effectEndHandler()[E:\dev\3.0.x\frameworks\projects\frame
work\src\mx\effects\Effect.as:1329]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at 
mx.effects::EffectInstance/finishEffect()[E:\dev\3.0.x\frameworks\projects\f
ramework\src\mx\effects\EffectInstance.as:651]
at 
mx.effects::EffectInstance/finishRepeat()[E:\dev\3.0.x\frameworks\projects\f
ramework\src\mx\effects\EffectInstance.as:690]
at 
mx.effects.effectClasses::TweenEffectInstance/onTweenEnd()[E:\dev\3.0.x\fram
eworks\projects\framework\src\mx\effects\effectClasses\TweenEffectInstance.a
s:395]
at 
mx.effects::Tween/endTween()[E:\dev\3.0.x\frameworks\projects\framework\src\
mx\effects\Tween.as:524]
at 
mx.effects::Tween/http://www.adobe.com/2006/flex/mx/internal::doInterval()[E
:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Tween.as:565]
at 
mx.effects::Tween$/timerHandler()[E:\dev\3.0.x\frameworks\projects\framework
\src\mx\effects\Tween.as:179]
at flash.utils::Timer/_timerDispatch()
at flash.utils::Timer/tick()

 



[flexcoders] Form Processing with Flash/Flex

2008-07-12 Thread brucewhealton
Hello all,
 I've recently gotten a good handle on using the spry
framework in Dreamweaver and the tags that are part of a good practice
when creating forms in DW.  Now, I'm looking at creating and
processing forms with Flash and Flex.  This is different.
 Can someone suggest some reading or content on the web, or
your own explanations that might help with doing this.  I can work
with PHP for form processing.  I want to be sure to setup my Flash and
Flex forms for processing correctly.  I do have some rather extensive
forms too.  I'm not just talking about a feedback form with 2 or 3
input text fields.
  It would be helpful to be able to check the forms for valid
entries... something that Javascript would do in a xhtml form.  
  Can someone recommend a good form processor that uses PHP? 
and would work fine with Flex/Flash, if that is an issue.
Thanks,
Bruce



[flexcoders] Re: Stupid question regarding sizing of mxml components

2008-07-12 Thread aduston1976
Hi dbronk, I need the top vbox to scroll but not the bottom one.
Assuming that your sdk is sufficiently similar to mine, the solution
you gave makes them both scroll. You can achieve this effect very
easily without the Canvas components in your solution: just set
height="50%" and minHeight="0" for both inner VBoxes. Unless I'm
missing something in your reply, the original problem remains
unsolved. Adam

--- In flexcoders@yahoogroups.com, "dbronk" <[EMAIL PROTECTED]> wrote:
>
> Not sure why, seems like a bug.  But if you wrap the inner vbox's in a
> canvas it works.
> 
>   
>horizontalScrollPolicy="off">
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
>horizontalScrollPolicy="off">
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
>   
> 
> 
> 
> 
> --- In flexcoders@yahoogroups.com, "Paul Andrews"  wrote:
> >
> > Have you tried setting the verticalScrollPolicy?
> > 
> > If you want to refer to specific containers, give them an id so we
> can be 
> > sure which is being refered to.
> > 
> > This might be helpful: 
> >
>
http://livedocs.adobe.com/flex/3/html/help.html?content=containers_intro_4.html
> > 
> > Paul
> > - Original Message - 
> > From: "aduston1976" 
> > To: 
> > Sent: Sunday, July 13, 2008 12:17 AM
> > Subject: [flexcoders] Stupid question regarding sizing of mxml
> components
> > 
> > 
> > > Hi, here is an easy one:
> > >
> > > 
> > > 
> > > ... lots of stuff ...
> > > 
> > > 
> > > ... lots of stuff ...
> > > 
> > > 
> > >
> > > When lots of stuff is added, I want the top inner VBox to show
> > > scrollbars, not the second. Any way to do this? Other than by
setting
> > > minHeight="0", which I've tried and which doesn't work?
> > >
> > > Here is a non-standard solution: I could change the outer VBox to a
> > > VBox inheritor and override updateDisplayList, and then set
> > > _first.height manually after calling super.updateDisplayList. Is
this
> > > totally wrong for any reason? Will I end up breaking Flex?
> > >
> > > Thanks,
> > > Adam
> > >
> > >
> > > 
> > >
> > > --
> > > Flexcoders Mailing List
> > > FAQ:
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > > Search Archives: 
> > > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo!
Groups 
> > > Links
> > >
> > >
> > >
> > >
> >
>




[flexcoders] Re: Stupid question regarding sizing of mxml components

2008-07-12 Thread dbronk
Not sure why, seems like a bug.  But if you wrap the inner vbox's in a
canvas it works.
































  



--- In flexcoders@yahoogroups.com, "Paul Andrews" <[EMAIL PROTECTED]> wrote:
>
> Have you tried setting the verticalScrollPolicy?
> 
> If you want to refer to specific containers, give them an id so we
can be 
> sure which is being refered to.
> 
> This might be helpful: 
>
http://livedocs.adobe.com/flex/3/html/help.html?content=containers_intro_4.html
> 
> Paul
> - Original Message - 
> From: "aduston1976" <[EMAIL PROTECTED]>
> To: 
> Sent: Sunday, July 13, 2008 12:17 AM
> Subject: [flexcoders] Stupid question regarding sizing of mxml
components
> 
> 
> > Hi, here is an easy one:
> >
> > 
> > 
> > ... lots of stuff ...
> > 
> > 
> > ... lots of stuff ...
> > 
> > 
> >
> > When lots of stuff is added, I want the top inner VBox to show
> > scrollbars, not the second. Any way to do this? Other than by setting
> > minHeight="0", which I've tried and which doesn't work?
> >
> > Here is a non-standard solution: I could change the outer VBox to a
> > VBox inheritor and override updateDisplayList, and then set
> > _first.height manually after calling super.updateDisplayList. Is this
> > totally wrong for any reason? Will I end up breaking Flex?
> >
> > Thanks,
> > Adam
> >
> >
> > 
> >
> > --
> > Flexcoders Mailing List
> > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives: 
> > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups 
> > Links
> >
> >
> >
> >
>




[flexcoders] Context menu triggers browser crash

2008-07-12 Thread Guy Morton
Hi there

I have a Flex 2 app that has a custom context menu attached to the
root application object. It works without incident on the Mac, but on
windows, choosing an item from the context menu sometimes causes the
browser to crash. 

There appears to be no pattern to it, though it does seem to occur
more frequently when choosing a menu item that calls a function that
does a couple of sequential HTTP requests and thus can take a little
while (maybe a second or two) to complete.

This happens in both IE and Firefox on windows, so for once we can't
just blame IE. :-)

Anyone seen this behaviour before and know what causes it, or how to
work around it?

TIA 

Guy




[flexcoders] Re: Stupid question regarding sizing of mxml components

2008-07-12 Thread aduston1976
Paul, Thanks for your reply.

> Have you tried setting the verticalScrollPolicy?

No, because looking at BoxLayout#measure, it seemed to have no impact
on the measure of the component. But, just to be sure, I just
empirically confirmed this.

> If you want to refer to specific containers, give them an id so we
can be 
> sure which is being refered to.

I put in ids at first, but they seemed to obfuscate more than they
helped, since there were only two inner VBoxes. But here is the
problem restated with ids:



... lots of stuff ...


... lots of stuff ...



How to make _top scroll only without _bottom scrolling?

> This might be helpful: 

Thanks for the link, but I'm afraid it didn't help me with this
particular problem. It is interesting, a search brought up several
similar posts in the past with the same question, but there's never
been an answer, just suggestions a la "have you tried minHeight=0?".
Just to be explicit, I have set minHeight and verticalScrollPolicy on
the relevant mxml elements in my example. I wonder if mxml provides
any way to solve this or if I have to use the updateDisplayList
override I described initially.

Adam

--- In flexcoders@yahoogroups.com, "Paul Andrews" <[EMAIL PROTECTED]> wrote:
>
> Have you tried setting the verticalScrollPolicy?
> 
> If you want to refer to specific containers, give them an id so we
can be 
> sure which is being refered to.
> 
> This might be helpful: 
>
http://livedocs.adobe.com/flex/3/html/help.html?content=containers_intro_4.html
> 
> Paul
> - Original Message - 
> From: "aduston1976" <[EMAIL PROTECTED]>
> To: 
> Sent: Sunday, July 13, 2008 12:17 AM
> Subject: [flexcoders] Stupid question regarding sizing of mxml
components
> 
> 
> > Hi, here is an easy one:
> >
> > 
> > 
> > ... lots of stuff ...
> > 
> > 
> > ... lots of stuff ...
> > 
> > 
> >
> > When lots of stuff is added, I want the top inner VBox to show
> > scrollbars, not the second. Any way to do this? Other than by setting
> > minHeight="0", which I've tried and which doesn't work?
> >
> > Here is a non-standard solution: I could change the outer VBox to a
> > VBox inheritor and override updateDisplayList, and then set
> > _first.height manually after calling super.updateDisplayList. Is this
> > totally wrong for any reason? Will I end up breaking Flex?
> >
> > Thanks,
> > Adam
> >
> >
> > 
> >
> > --
> > Flexcoders Mailing List
> > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives: 
> > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups 
> > Links
> >
> >
> >
> >
>




[flexcoders] dynamic move

2008-07-12 Thread [EMAIL PROTECTED]
In this code I'm dynamically creating an HBox, adding an image to it, 
adding the box to a Panel,  and then creating a Move() to move the Hbox.
It produces the error below, which says "value" is not a function. WHAT 
VALUE? Why doesn't it name the value ?  What did I do wrong ?
The error comes when I add the final line, moveSketch.play();



var sketchBox:HBox = new HBox();
   var sketchImg:Image=new Image;
   sketchImg.source="Journeysketchsm.gif";
   sketchBox.addChild(sketchImg);
   thePanel.addChildAt(sketchBox,0);

var moveSketch:Move = new Move();
moveSketch.target="sketchBox";
moveSketch.xTo=150;
moveSketch.duration=3000;
moveSketch.play();
 

TypeError: Error #1006: value is not a function.
at 
mx.effects::EffectInstance/play()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\EffectInstance.as:584]
at 
mx.effects.effectClasses::MoveInstance/play()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\effectClasses\MoveInstance.as:230]
at 
mx.effects::EffectInstance/startEffect()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\EffectInstance.as:569]
at 
mx.effects::Effect/play()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Effect.as:930]
at jbh/endEffectHandler()[K:\flex3\src\jbh.mxml:60]
at jbh/___jbh_AnimateProperty1_effectEnd()[K:\flex3\src\jbh.mxml:9]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at 
mx.effects::Effect/effectEndHandler()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Effect.as:1329]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at 
mx.effects::EffectInstance/finishEffect()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\EffectInstance.as:651]
at 
mx.effects::EffectInstance/finishRepeat()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\EffectInstance.as:690]
at 
mx.effects.effectClasses::TweenEffectInstance/onTweenEnd()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\effectClasses\TweenEffectInstance.as:395]
at 
mx.effects::Tween/endTween()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Tween.as:524]
at 
mx.effects::Tween/http://www.adobe.com/2006/flex/mx/internal::doInterval()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Tween.as:565]
at 
mx.effects::Tween$/timerHandler()[E:\dev\3.0.x\frameworks\projects\framework\src\mx\effects\Tween.as:179]
at flash.utils::Timer/_timerDispatch()
at flash.utils::Timer/tick()



Re: [flexcoders] Stupid question regarding sizing of mxml components

2008-07-12 Thread Paul Andrews
Have you tried setting the verticalScrollPolicy?

If you want to refer to specific containers, give them an id so we can be 
sure which is being refered to.

This might be helpful: 
http://livedocs.adobe.com/flex/3/html/help.html?content=containers_intro_4.html

Paul
- Original Message - 
From: "aduston1976" <[EMAIL PROTECTED]>
To: 
Sent: Sunday, July 13, 2008 12:17 AM
Subject: [flexcoders] Stupid question regarding sizing of mxml components


> Hi, here is an easy one:
>
> 
> 
> ... lots of stuff ...
> 
> 
> ... lots of stuff ...
> 
> 
>
> When lots of stuff is added, I want the top inner VBox to show
> scrollbars, not the second. Any way to do this? Other than by setting
> minHeight="0", which I've tried and which doesn't work?
>
> Here is a non-standard solution: I could change the outer VBox to a
> VBox inheritor and override updateDisplayList, and then set
> _first.height manually after calling super.updateDisplayList. Is this
> totally wrong for any reason? Will I end up breaking Flex?
>
> Thanks,
> Adam
>
>
> 
>
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives: 
> http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups 
> Links
>
>
>
> 



Re: [flexcoders] Component Questions

2008-07-12 Thread Dan Vega
That is a ton of information Greg, thanks so much! I have viewed the Lynda
videos before so I guess its about time to revisit them. I think once I wrap
my head around how to move data around I will be ready to jump into a
framework, after that sky is the limit! Thanks again for the info..


Dan



On Sat, Jul 12, 2008 at 7:31 PM, greg h <[EMAIL PROTECTED]> wrote:

>   Hi Dan,
>
> For more of a walk through on "Dispatching Events from Custom Components"
> see this online training title from Lynda.com:
>
> Flex 3 Essential Training with: David Gassner
> http://movielibrary.lynda.com/html/modPage.asp?ID=438
>
> If you do not already have an account for the lynda.com Online Training
> Library, you can sign up for a 7-day Free Trial here (requires only an email
> address to sign up):
> http://www.lynda.com/freepass
>
> For your immediate requirement see:
> 10. Programming with Events
> Dispatching Events from Custom Components
> Creating and using custom event classes
> Dispatching and handling custom events
>
> Regarding Alex's comment, I concur.
>
> The following Lynda.com Online Training title can introduce you to the
> basics on "Centralizing data storage with the ModelLocator pattern".
>
> Flex 2 Beyond the Basics with: David Gassner
> http://movielibrary.lynda.com/html/modPage.asp?ID=290
>
> 9. Client-Side Data Handling
> Centralizing data storage with the ModelLocator pattern
>
> Note:  This lynda.com training video on the ModelLocator pattern
> references (but does not use) the Cairngorm "microarchitecture".  The
> training video covers just using a "microarchitecture free" implementation
> of a singleton ModelLocator class.  This will give you the simplest, most
> straightforward understanding of what Alex is referring too.  (Highly
> recommended.)
>
> Several microarchitectures are sometimes used in Flex developement that
> implement more design patterns than just ModelLocator.  Two that I am most
> familiar with are Cairngorm and PureMVC.org.  Just be forewarned that in
> structuring your codebase around these microarchitectures you will be
> committing to some significant overhead in terms of learning and the
> ultimate organization of your codebase. (Meaning, save them for some project
> after your first ever MVC in Flex project :-)
>
> Using microarchitetures like Cairngorm do ensure the use of a singleton
> ModelLocator classes.  For primers on Cairngorm see:
> http://cairngormdocs.org/
> http://labs.adobe.com/wiki/index.php/Cairngorm
>
> And this must read:
> Why I think you shouldn't use Cairngorm
>
> http://weblogs.macromedia.com/swebster/archives/2006/08/why_i_think_you.html
>
> For Cairngorm specific support see:
> http://tech.groups.yahoo.com/group/cairngorm-documentation/
>
> hth,
>
> g
>  
>


Re: [flexcoders] Component Questions

2008-07-12 Thread greg h
Hi Dan,

For more of a walk through on "Dispatching Events from Custom Components"
see this online training title from Lynda.com:

Flex 3 Essential Training with: David Gassner
http://movielibrary.lynda.com/html/modPage.asp?ID=438

If you do not already have an account for the lynda.com Online Training
Library, you can sign up for a 7-day Free Trial here (requires only an email
address to sign up):
http://www.lynda.com/freepass

For your immediate requirement see:
10. Programming with Events
Dispatching Events from Custom Components
Creating and using custom event classes
Dispatching and handling custom events

Regarding Alex's comment, I concur.

The following Lynda.com Online Training title can introduce you to the
basics on "Centralizing data storage with the ModelLocator pattern".

Flex 2 Beyond the Basics with: David Gassner
http://movielibrary.lynda.com/html/modPage.asp?ID=290

9. Client-Side Data Handling
Centralizing data storage with the ModelLocator pattern

Note:  This lynda.com training video on the ModelLocator pattern references
(but does not use) the Cairngorm "microarchitecture".  The training video
covers just using a "microarchitecture free" implementation of a singleton
ModelLocator class.  This will give you the simplest, most straightforward
understanding of what Alex is referring too.  (Highly recommended.)

Several microarchitectures are sometimes used in Flex developement that
implement more design patterns than just ModelLocator.  Two that I am most
familiar with are Cairngorm and PureMVC.org.  Just be forewarned that in
structuring your codebase around these microarchitectures you will be
committing to some significant overhead in terms of learning and the
ultimate organization of your codebase. (Meaning, save them for some project
after your first ever MVC in Flex project :-)

Using microarchitetures like Cairngorm do ensure the use of a singleton
ModelLocator classes.  For primers on Cairngorm see:
http://cairngormdocs.org/
http://labs.adobe.com/wiki/index.php/Cairngorm

And this must read:
Why I think you shouldn't use Cairngorm
http://weblogs.macromedia.com/swebster/archives/2006/08/why_i_think_you.html

For Cairngorm specific support see:
http://tech.groups.yahoo.com/group/cairngorm-documentation/

hth,

g


Re: [flexcoders] Component Questions

2008-07-12 Thread Dan Vega
Any examples would be a big help!.



On Sat, Jul 12, 2008 at 7:30 PM, Dan Vega <[EMAIL PROTECTED]> wrote:

> I agree with you but is there an easy way to do this without diving into a
> framework right away? I understand frameworks in general but I am still
> learning the ins and outs of Flex. I am just trying to go up the 45 degree
> ramp instead of the 90 :)
>
> THanks!
>
>
> "I seem to be in the minority opinion on this topic, and you must also
> know that I develop framework components and not full-fledged production
> applications, but if you are headed to MVC, there should be a central model
> class that contains the data, and the UI should only reference the model's
> data and not really "own" it, or the services that fetch the data, and when
> the UI is manipulated, the UI should update the model, and not really
> dispatch events for other UI to manage."
>


Re: [flexcoders] Component Questions

2008-07-12 Thread Dan Vega
I agree with you but is there an easy way to do this without diving into a
framework right away? I understand frameworks in general but I am still
learning the ins and outs of Flex. I am just trying to go up the 45 degree
ramp instead of the 90 :)

THanks!

"I seem to be in the minority opinion on this topic, and you must also know
that I develop framework components and not full-fledged production
applications, but if you are headed to MVC, there should be a central model
class that contains the data, and the UI should only reference the model's
data and not really "own" it, or the services that fetch the data, and when
the UI is manipulated, the UI should update the model, and not really
dispatch events for other UI to manage."


[flexcoders] Stupid question regarding sizing of mxml components

2008-07-12 Thread aduston1976
Hi, here is an easy one:



... lots of stuff ... 


... lots of stuff ... 



When lots of stuff is added, I want the top inner VBox to show
scrollbars, not the second. Any way to do this? Other than by setting
minHeight="0", which I've tried and which doesn't work?

Here is a non-standard solution: I could change the outer VBox to a
VBox inheritor and override updateDisplayList, and then set
_first.height manually after calling super.updateDisplayList. Is this
totally wrong for any reason? Will I end up breaking Flex?

Thanks,
Adam



RE: [flexcoders] Component Questions

2008-07-12 Thread Alex Harui
I seem to be in the minority opinion on this topic, and you must also
know that I develop framework components and not full-fledged production
applications, but if you are headed to MVC, there should be a central
model class that contains the data, and the UI should only reference the
model's data and not really "own" it, or the services that fetch the
data, and when the UI is manipulated, the UI should update the model,
and not really dispatch events for other UI to manage.

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Dan Vega
Sent: Saturday, July 12, 2008 2:45 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Component Questions

 

Ok, I re wrote the 1st screen into a component. Here is the code for my
component. When a user selects a client from the data grid I want to
dispatch an event of "clientSelected" My question now is in my main app
I have the following code. How do I tell my main application to listen
for that event? addEventListener("clientSelected",onClientSelect) does
not work? Also all of my "screens" have next and previous buttons and
when the app was all in one file i was able to change states. Now that I
am in a component how can i change the state? Thanks for your help!!










http://www.adobe.com/2006/mxml
 "
width="100%" height="100%" layout="vertical" 
title="Rogers Image Uploader - Start" 
backgroundColor="#000" initialize="init();">









 






















 



Re: [flexcoders] Component Questions

2008-07-12 Thread greg h
Hi Dan,

I think you might need to include the [Event] metadata tag in your
components that are executing dispatchEvent().

Something like this:


[Event(name="clientSelected")]


For details see this page in the docs:
http://livedocs.adobe.com/flex/3/html/createevents_3.html#160168
And at this link, go to #2 at the top of the page and select the link for
"Using the Event metadata tag"

The text under that section starts off ...
You use the [Event] metadata tag to define events dispatched by a component
so that the Flex compiler can recognize them as MXML tag attributes in an
MXML file. ...

hth,

g


[flexcoders] Re: YouTube AS3 Support

2008-07-12 Thread comfederation
--- In flexcoders@yahoogroups.com, "comfederation" <[EMAIL PROTECTED]>
wrote:
>
> Believe it or not, YouTube hacked together an AS2 implementation of a
> chromeless player. AS3 support is nowhere to be seen.
> 
> Please help all of us by clicking on this link and then voting for
> this issue by clicking on the star, to the left of "Isse 416:".
> http://code.google.com/p/you-issues/issues/detail?id=416
> 
> Regards,
> Zdravko
>

I've cut & pasted the URL so I have no idea why it's not working or
how in the URL ".../gdata-issues/..." got changed to
".../you-issues/..."
ttp://code.google.com/p/gdata-issues/issues/detail?id=416

While you are there, could you also take a look at and support issue
641 tat http://code.google.com/p/gdata-issues/issues/detail?id=641





[flexcoders] FormItem Multiline Labels Possible?

2008-07-12 Thread P Smith
A designer has requested a 2 line form label.
 
FormItem's label property instantiates a descendent of .  And 
obviously,  supports only single line text (or single line htmlText).
 
I looked at the source on FormItem.as.  Before putting time in to extend 
FormItem, I am posting here to see if anyone else may have developed a solution 
that they would share?
 
Short of that, following is an embarrassing hack:




Thanks
 


  

Re: [flexcoders] Module hell... Flex 3

2008-07-12 Thread Sebastian Mohr
Hi Alex,

when I call the CairngormEvent
the first time just like this:

   new LoadTestEvent().dispatch();

the moduleReadyHandler - method
will not be called. But when I call the
LoadTestEvent a second time, once
again, just like this:

   new LoadTestEvent().dispatch()

the moduleReadyHandler - method
will be successfully called.

I believe that the two EventListeners:

   ModuleEvent.READY and
   ModuleEvent.ERROR

are not registered correctly in the first place.
But I don't understand why!? Maybe there is
an issue related to the FrontController?

Thank you,
masu


On 7/12/08, Alex Harui <[EMAIL PROTECTED]> wrote:
>
> I'm not sure I see the event logic you're talking about.
>
>
> --
>
> *From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] *On
> Behalf Of *Sebastian Mohr
> *Sent:* Saturday, July 12, 2008 9:22 AM
> *To:* flexcoders@yahoogroups.com
> *Subject:* Re: [flexcoders] Module hell... Flex 3
>
>
>
> Hi there,
>
> I have the same problem as *dbronk *mentioned
> (see below) in conjunction with Cairngorm 2.2.1.
>
> I always have to dispatch the LoadTestEvent
> twice to make the LoadTestCommand calling
> the moduleReadyHandler-method. here is the
> code:
>
> package com.test
> {
>import com.adobe.cairngorm.commands.ICommand;
>import com.adobe.cairngorm.control.CairngormEvent;
>
>import flash.system.ApplicationDomain;
>
>import mx.events.ModuleEvent;
>import mx.modules.IModuleInfo;
>import mx.modules.ModuleManager;
>
>public class LoadTestCommand implements ICommand
>{
>   private var moduleInfo:IModuleInfo;
>
>   public function LoadTestCommand()
>   {
>  moduleInfo = ModuleManager.getModule('TestModule.swf');
>  moduleInfo.addEventListener(ModuleEvent.READY,
> moduleReadyHandler);
>  moduleInfo.addEventListener(ModuleEvent.ERROR,
> moduleErrorHandler);
>   }
>
>   public function execute(event:CairngormEvent):void
>   {
>  moduleInfo.load(ApplicationDomain.currentDomain);
>   }
>
>   public function moduleReadyHandler(e:ModuleEvent) : void
>   {
>  trace('SUCCESS');
>   }
>
>   public function moduleErrorHandler(e:ModuleEvent) : void
>   {
>  trace('ERROR');
>   }
>}
> }
>
> Is there a solution to dispatch the event only once
> to make the Command loading the module?
>
> Thank you,
> masu
>
>
> On 1/28/08, *dbronk* <[EMAIL PROTECTED]> wrote:
>
> I'm trying to get something very basic to work with modules. I have
> my app and two swf modules (Form1.swf and Form2.swf). Each test
> module simply has a couple TextInput fields. I have also extended
> Module so I can follow what is going on and I will be adding custom
> code later. MyModule extends Module has:
>
> public function MyModule() {
> super();
> trace("Module constructor");
> addEventListener(FlexEvent.INITIALIZE, onInitialize);
> }
>
> protected function onInitialize(event:Event) : void {
> trace("Module.onInit: " + this.toString());
> dispatchEvent(new BaseEvent("moduleLoaded", this, true, true));
> }
>
> Very basic. I want to be notified when the Module is initialized.
>
> When I have the following code inline to a button click which will
> load the module it works fine
>
> var moduleLoader : ModuleLoader = new ModuleLoader();
> moduleLoader.id = moduleName;
> moduleLoader.url = moduleName;
> moduleLoader.loadModule();
> moduleLoader.addEventListener("moduleLoaded", onModuleLoaded);
> moduleStackChild = moduleLoader;
> moduleStack.addChild(moduleStackChild);
> moduleMap.put(moduleName, moduleStackChild);
>
> My onModuleLoaded function gets called.
>
> Now for the issue. If I take this code and place it into a common
> object it no longer works THE FIRST TIME. I have two buttons, one to
> load Form1.swf and the other to load Form2.swf. When this code to
> load the module is in a separate class, it doesn't matter if I click
> button 1 or 2 first. It simply will not work on the first click.
> Second click and beyond work fine. Also, in debug mode, works great
> every time. What happens is that the last thing that runs is the
> loadModule() command. The constructor on MyModule never executes on
> the first execution. Future executions work fine.
>
> I'm hoping I explained this good enough as it is very strange. But I
> definitely want to have this function in my util classes and not have
> to duplicate the code all over the place.
>
> Suggestions?
>
> Thanks,
> Dale
>
>
> 
>


Re: [flexcoders] Component Questions

2008-07-12 Thread Dan Vega
Ok, I re wrote the 1st screen into a component. Here is the code for my
component. When a user selects a client from the data grid I want to
dispatch an event of "clientSelected" My question now is in my main app I
have the following code. How do I tell my main application to listen for
that event? addEventListener("clientSelected",onClientSelect) does not work?
Also all of my "screens" have next and previous buttons and when the app was
all in one file i was able to change states. Now that I am in a component
how can i change the state? Thanks for your help!!










http://www.adobe.com/2006/mxml";
width="100%" height="100%" layout="vertical"
title="Rogers Image Uploader - Start"
backgroundColor="#000" initialize="init();">

































[flexcoders] Re: flash player version picker in Firefox?

2008-07-12 Thread Oliver Merk
http://www.sephiroth.it/firefox/flash_switcher/
Now working in Linux and Mac as well!

--- In flexcoders@yahoogroups.com, "Scott Langeberg" <[EMAIL PROTECTED]>
wrote:
>
> Anyone remember an extension for firefox (I think) that lets you pick
which
> of your installed flash players to use in the browser, on the fly?
That
> thing was handy, when it worked...
>
> --
> : : ) Scott
>
> Helping your grandma on the interweb
> at: http://blog.criticalpile.com
>




[flexcoders] Re: Parallel requests using RemoteObject with RTMP

2008-07-12 Thread mmormando
It doesn't have anything to do with Flex, its IE. IE 6 and I believe
7, and Firefox 2 all default to only allow 2 downloads from a single
subdomain. I got that from the folks at Yahoo that bring us the YSlow
stuff. If you are using an Apache front end you could make your
request to multiple subdomains, e.g. data1.yourdomain.com and
data2.yourdomain.com would let you go to 4, conversely if you have
control of all the computers hitting your service there are registry
tweaks you can set, something along the lines of
max_server_connections, that's from memory so don't take it as
doctrine. I've also read that IE 8 beta defaults to something like 30.
I'm using Firefox 3 and set it to 30, as well as allowed it to use
http pipelining, up to 30 requests per socket, and things seem to just
scream!!
Good luck
Mike




[flexcoders] YouTube AS3 Support

2008-07-12 Thread comfederation
Believe it or not, YouTube hacked together an AS2 implementation of a
chromeless player. AS3 support is nowhere to be seen.

Please help all of us by clicking on this link and then voting for
this issue by clicking on the star, to the left of "Isse 416:".
http://code.google.com/p/you-issues/issues/detail?id=416

Regards,
Zdravko




[flexcoders] Why does IE7 display " # " for tab title?

2008-07-12 Thread paulbohnenkamp
In IE7 I see the tab title appears with the correct logo but a label
of simply " # ". In Firefox the tab is correctly labeled.

In the jsp that launches the app the title tag is there and set.

Does anyone know the fix for IE7 to show the title correctly?



Re: [flexcoders] Component Questions

2008-07-12 Thread Dan Vega
Thanks for the quick reply Douglas..

I know about the _ for private variables, I am just in the process of
breaking my app up. Am I doing things thre right way then ? I have an ojbect
that 3 of the 4 screens either need to read or update. Do I create a public
var and pass it around ?



On Sat, Jul 12, 2008 at 3:23 PM, Douglas Knudsen <[EMAIL PROTECTED]>
wrote:

>   You need to inject data from parents into children. If children need
> to send data up the chain to parents, use a event. Thus, in the below
> add a public variable client and set this upon creation like this
>
> 
> note its odd to name a publicly available variable with a _
>
> DK
>
>
> On Sat, Jul 12, 2008 at 2:46 PM, Dan Vega <[EMAIL 
> PROTECTED]>
> wrote:
> > I built a small app that has 4 screens and everything is working great. I
> > want to learn more about breaking up the views into different components
> > before I move on to mvc in Flex. My question is lets say I have my main
> > application and then each of my screens are views. In my main application
> I
> > have a public variable called _client. On the first view I am trying to
> > access that object and the compiler is telling me it is undefined. In my
> > code you will the line _client = selected.
> >
> > My question is how does the component know about the data declared in the
> > main application ?
> >
> > 
> > http://www.adobe.com/2006/mxml";
> > width="100%" height="100%" layout="vertical"
> > title="Rogers Image Uploader - Start"
> > backgroundColor="#000"
> > creationComplete="init()">
> >
> > 
> > 
> > 
> >
> >  > height="100%">
> > 
> >  > width="40"/>
> >  > width="250"/>
> > 
> > 
> > 
> > 
> >  > labelFunction="statusRenderer"/>
> > 
> > 
> >
> > 
> > 
> > 
> > 
> > 
> >  > click="{this.currentState='uploader'}"/>
> > 
> > 
> >
> > Thank You
> > Dan Vega
> > [EMAIL PROTECTED] 
> > http://www.danvega.org
> >
> >
>
> --
> Douglas Knudsen
> http://www.cubicleman.com
> this is my signature, like it?
>  
>


Re: [flexcoders] Component Questions

2008-07-12 Thread Douglas Knudsen
You need to inject data from parents into children.  If children need
to send data up the chain to parents, use a event.  Thus, in the below
add a public variable client and set this upon creation like this

 wrote:
> I built a small app that has 4 screens and everything is working great. I
> want to learn more about breaking up the views into different components
> before I move on to mvc in Flex. My question is lets say I have my main
> application and then each of my screens are views. In my main application I
> have a public variable called _client. On the first view I am trying to
> access that object and the compiler is telling me it is undefined. In my
> code you will the line _client = selected.
>
> My question is how does the component know about the data declared in the
> main application ?
>
> 
> http://www.adobe.com/2006/mxml";
> width="100%" height="100%" layout="vertical"
> title="Rogers Image Uploader - Start"
> backgroundColor="#000"
> creationComplete="init()">
>
> 
> 
> 
>
>  height="100%">
> 
>  width="40"/>
>  width="250"/>
> 
> 
> 
> 
>  labelFunction="statusRenderer"/>
> 
> 
>
> 
> 
> 
> 
> 
>  click="{this.currentState='uploader'}"/>
> 
> 
>
> Thank You
> Dan Vega
> [EMAIL PROTECTED]
> http://www.danvega.org
>
> 



-- 
Douglas Knudsen
http://www.cubicleman.com
this is my signature, like it?


[flexcoders] Component Questions

2008-07-12 Thread Dan Vega
I built a small app that has 4 screens and everything is working great. I
want to learn more about breaking up the views into different components
before I move on to mvc in Flex. My question is lets say I have my main
application and then each of my screens are views. In my main application I
have a public variable called _client. On the first view I am trying to
access that object and the compiler is telling me it is undefined. In my
code you will the line _client = selected.

My question is how does the component know about the data declared in the
main application ?


http://www.adobe.com/2006/mxml";
width="100%" height="100%" layout="vertical"
title="Rogers Image Uploader - Start"
backgroundColor="#000"
creationComplete="init()">


























Thank You
Dan Vega
[EMAIL PROTECTED]
http://www.danvega.org


RE: {Disarmed} RE: [flexcoders] Calling AS3 functions

2008-07-12 Thread Alex Harui
If another mxml file is a state, then its stuff may not exist until you
are in that state.  I'm not sure how you set that up though.  That's the
kind of code that might help us see what is going wrong.

 

Normally, if I have two MXML files:

 

-loginForm.mxml





Public function foo() {}





 

-login.mxml-







Private function callFoo() { bar.foo() }





 

I'm guessing that the object doesn't exist yet since the compiler seemed
to like what you are doing.

 

-Alex



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Scott
Sent: Saturday, July 12, 2008 5:39 AM
To: flexcoders@yahoogroups.com
Subject: RE: {Disarmed} RE: [flexcoders] Calling AS3 functions

 

Yes, I did change that already it does say returnEmail on both sides
now.

 

Very interesting...  

 

This would be a better question then...  

 

I've got a login.mxml file which controls the different states the login
can be in.  Each state essentially is another mxml file.  I'm calling a
CFC function to process the login which is in the loginForm.mxml.  This
function has the email address and name as returned by the CFC.  How can
I pull that information out and into the login.mxml file?  So if what
you are saying is that each of the files are their own class, I would
need a way to call that class from another class.

 

I did change that method to be public but still wasn't able to "see" it.
What is the syntax to access an external class from another class?  Do I
need to reference class.function()?

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Alex Harui
Sent: Saturday, July 12, 2008 12:34 AM
To: flexcoders@yahoogroups.com
Subject: {Disarmed} RE: [flexcoders] Calling AS3 functions

 

Each mxml has its own (document) scope.  It essentially defines a class.
A method must be public in order to be accessed from outside the class,
you cannot access protected from outside the class.

 

Your snippet doesn't have id's or show the relationship between the two
classes so it is hard to say why it isn't working. Also, you appear to
be trying to call returnEmail when the snippet only showed a returnName
method.

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Scott
Sent: Friday, July 11, 2008 8:30 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Calling AS3 functions

 

I'm still getting the same error...

 

The class exists in the loginForm.mxml but the mxml code exists in the
login.mxml file.

 

Is there something special I have to do to use the functions that exist
in the other mxml file?

 

Better yet, is there a way to access variables other than setting up a
function in the active script?

 

 Thanks much.

 

---


All AS code needs to be inside the curly braces and you need to
concatenate your static string to the string returned from your function

 

 

--

 

I'm working on a logon class in Flex 3.  I've got a login.mxml which
controls the overall views (logon/register/logout) all in the same box
depending on what state the user is in.

 

In the loginForm.mxml (included in the logon.mxml), I've got a function
called protected returnName():String

 

 

Function I want to call from the loginForm AS3 script:

protected function returnName():String   (I've also tried public in case
it was not available in that area of code)

{

   return this.username.text;

}

 

Snippet from my mxml code:

Xmlns:login="com.ft.views.login.*";

 

...

 



 

   



   



   

  <-
line in question 



   









 

I can't seem to figure out how to reference the method as I get the
error: 1180: Call to a possibly undefined method returnName.

 

I've tried:





Among many others...

 

This is probably pretty simple.  I really appreciate your help.

 


-- 
This message has been scanned for viruses and 
dangerous content by MailScanner  , and is

believed to be clean. 


-- 
This message has been scanned for viruses and 
dangerous content by MailScanner  , and is

believed to be clean. 

 



[flexcoders] flash player version picker in Firefox?

2008-07-12 Thread Scott Langeberg
Anyone remember an extension for firefox (I think) that lets you pick which
of your installed flash players to use in the browser, on the fly? That
thing was handy, when it worked...

-- 
: : ) Scott

Helping your grandma on the interweb
at: http://blog.criticalpile.com


RE: [flexcoders] Flex Text Selection Problem...

2008-07-12 Thread Alex Harui
In actionscript, you can't use {} to bind.  You have to use
ChangeWatcher and/or other.mx.binding classes.

 

However, I usually just assign when the result from the server comes in
and skip binding altogether.

 

-Alex

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Toby Ashley
Sent: Friday, July 11, 2008 5:22 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Flex Text Selection Problem...

 

Corey,

There are some potential workarounds which Ive seen, all using similar
techniques to the one found here -
http://labs.hellokeita.com/2008/03/13/textfield-selection-color/
 

It's not ideal by any means and won't work for all situations, but
depending on what you need, it may be of use.

Cheers
toby

On Sat, Jul 12, 2008 at 12:10 AM, Corey Bray <[EMAIL PROTECTED]
 > wrote:


   Thanks Gordon...that will save me lots of time.


Gordon Smith wrote:
>
>
> Unfortunately, FP9 doesn't support setting the text selection color.
>
>
>
> Gordon Smith
>
> Adobe Flex SDK Team
>
>
>
>

>
>
> *From:* flexcoders@yahoogroups.com 

> [mailto:flexcoders@yahoogroups.com 
] *On Behalf Of *Corey Bray *Sent:*
> Friday, July 11, 2008 2:37 PM *To:* flexcoders@yahoogroups.com
 
> *Subject:* [flexcoders] Flex Text Selection Problem...
>
>
>
> Hey,
>
> I'm new to the list and was hoping I could get a little help with a
> problem in flex that is driving me nuts.
>
> Here's the problem - when you have a TextInput control whose
> background color is black and whose text is white, how do you change
> the color of the selected text so that it's distinguishable from text
> that is not selected? I have tried changing every color-related
> property I could find but was not able to change the color of the
> selection.
>
>   xmlns:mx="http://www.adobe.com/2006/mxml
 
>  >"
layout="horizontal"
> backgroundColor="#00">  TextInput { color: #FF;
> background-color: #00; backgroundAlpha: 0.0; dropShadowEnabled:
> false; borderThickness: 2; borderStyle: solid; font-size: 18; }
> 
>
> 
>
> 
>
> Corey...
>
>




--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 

Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo
 ! Groups
Links

   http://groups.yahoo.com/group/flexcoders/
 


   (Yahoo! ID required)

   mailto:[EMAIL PROTECTED]
 



 

 



[flexcoders] Re: 3 tier architecture using adobe flex

2008-07-12 Thread markgoldin_2000
Well, Flex and FP are presentation layers. You would need to have
something running on the server. I am using a traditional ASP that
calls OLE servers that in turn talk to the SQL back-end.

Mark

--- In flexcoders@yahoogroups.com, "litesh_b321" <[EMAIL PROTECTED]> wrote:
>
> How to design a 3 tier architecture using adobe flex
>




RE: [flexcoders] Module hell... Flex 3

2008-07-12 Thread Alex Harui
I'm not sure I see the event logic you're talking about.

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Sebastian Mohr
Sent: Saturday, July 12, 2008 9:22 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Module hell... Flex 3

 

Hi there,

I have the same problem as dbronk mentioned 
(see below) in conjunction with Cairngorm 2.2.1.

I always have to dispatch the LoadTestEvent 
twice to make the LoadTestCommand calling 
the moduleReadyHandler-method. here is the 
code:

package com.test
{
   import com.adobe.cairngorm.commands.ICommand;
   import com.adobe.cairngorm.control.CairngormEvent;

   import flash.system.ApplicationDomain;

   import mx.events.ModuleEvent;
   import mx.modules.IModuleInfo;
   import mx.modules.ModuleManager;

   public class LoadTestCommand implements ICommand
   {
  private var moduleInfo:IModuleInfo;

  public function LoadTestCommand()
  {
 moduleInfo = ModuleManager.getModule('TestModule.swf');
 moduleInfo.addEventListener(ModuleEvent.READY,
moduleReadyHandler);
 moduleInfo.addEventListener(ModuleEvent.ERROR,
moduleErrorHandler);
  }

  public function execute(event:CairngormEvent):void
  {
 moduleInfo.load(ApplicationDomain.currentDomain);
  }

  public function moduleReadyHandler(e:ModuleEvent) : void
  {
 trace('SUCCESS');
  }

  public function moduleErrorHandler(e:ModuleEvent) : void
  {
 trace('ERROR');
  }
   }
}

Is there a solution to dispatch the event only once 
to make the Command loading the module?

Thank you,
masu




On 1/28/08, dbronk <[EMAIL PROTECTED]  >
wrote:

I'm trying to get something very basic to work with modules. I have
my app and two swf modules (Form1.swf and Form2.swf). Each test
module simply has a couple TextInput fields. I have also extended
Module so I can follow what is going on and I will be adding custom
code later. MyModule extends Module has:

public function MyModule() {
super();
trace("Module constructor");
addEventListener(FlexEvent.INITIALIZE, onInitialize);
}

protected function onInitialize(event:Event) : void {
trace("Module.onInit: " + this.toString());
dispatchEvent(new BaseEvent("moduleLoaded", this, true, true));
} 

Very basic. I want to be notified when the Module is initialized.

When I have the following code inline to a button click which will
load the module it works fine

var moduleLoader : ModuleLoader = new ModuleLoader();
moduleLoader.id = moduleName;
moduleLoader.url = moduleName;
moduleLoader.loadModule();
moduleLoader.addEventListener("moduleLoaded", onModuleLoaded);
moduleStackChild = moduleLoader;
moduleStack.addChild(moduleStackChild);
moduleMap.put(moduleName, moduleStackChild);

My onModuleLoaded function gets called.

Now for the issue. If I take this code and place it into a common
object it no longer works THE FIRST TIME. I have two buttons, one to
load Form1.swf and the other to load Form2.swf. When this code to
load the module is in a separate class, it doesn't matter if I click
button 1 or 2 first. It simply will not work on the first click. 
Second click and beyond work fine. Also, in debug mode, works great
every time. What happens is that the last thing that runs is the
loadModule() command. The constructor on MyModule never executes on
the first execution. Future executions work fine.

I'm hoping I explained this good enough as it is very strange. But I
definitely want to have this function in my util classes and not have
to duplicate the code all over the place.

Suggestions?

Thanks,
Dale

 

 



Re: [flexcoders] SQLlite limitations

2008-07-12 Thread George
Whatever you should retrieve data in parts if too much rows.

var stmt:SQLStatement = new SQLStatement();
stmt.sqlConnection = conn;
stmt.text = "SELECT ...";
stmt.addEventListener(SQLEvent.RESULT, selectResult);
stmt.execute(20); // only the first 20 rows (or fewer) are returned

function selectResult(event:SQLEvent):void
{ var result:SQLResult = stmt.getResult();
if (result.data != null) { // ... loop through the rows or perform other 
processing ...
 if (!result.complete) {
stmt.next(20); // retrieve the next 20 rows
} else { stmt.removeEventListener(SQLEvent.RESULT, selectResult);
} } }



Josh Millstein wrote:
>
> Hello,
>
> My AIR app is crashing on a sql statement (I think) that is returning 
> around
> 4 rows. Should that be happening? Is there a max execution time for
> sql queries that could be crashing adl? Is there anything I can do to fix
> this problem, if the execution time or the number rows returned is a
> problem?
>
> Thanks,
> Josh
> -- 
> [EMAIL PROTECTED] 
> 785-832-9154
>
> __.



[flexcoders] SQLlite limitations

2008-07-12 Thread Josh Millstein
Hello,

My AIR app is crashing on a sql statement (I think) that is returning around
4 rows.  Should that be happening?  Is there a max execution time for
sql queries that could be crashing adl?  Is there anything I can do to fix
this problem, if the execution time or the number rows returned is a
problem?

Thanks,
Josh
-- 
[EMAIL PROTECTED]
785-832-9154





[flexcoders] Re: looking for best Data Service

2008-07-12 Thread markgoldin_2000
If you are looking for a true push solution take a look at
Lightstreamer push server. They have examples for Flex. I have created
 a push solution based on the Lightstreamer push server, .Net data
adapter, Flex JS bridge, and a few more things. Took me some time but
it works very good. I haven't tested it in environment as heavy on
users as yours, but it looks very promising for upscaling. I would
suggest to take a look at the LS push server, and their samples. BTW,
documentation is very good. Then if you would want I can show what I
have so far.

Mark

--- In flexcoders@yahoogroups.com, Cameron <[EMAIL PROTECTED]> wrote:
>
> I've got a flex app that needs to update data routinely (about once per 
> minute). The data is stored in a database on my server and there could 
> be several 10's to hundreds of users who are looking at the data 
> simultaneously via the flex app. The data is represented by colored
dots 
> on a map. When the data changes, and it does about once per minute, I 
> basically need to update the color of one or potentially several 
> thousand objects on the map. I'd like for the changes to be seen by all 
> users at the same time (data push right?). I've seen a tutorial online 
> (the horse race one) about doing something similar, but it required the 
> Adobe Media Server on the server side. Is there a cheaper and better
way 
> to do this using one of the open source AMF's out there? I've played 
> around with AMF::Perl, but it doesn't seem to have the data push 
> capability, only responds to requests as far as I can tell. Has anyone 
> done something like this? If so what did you use? I'm working with 
> Win2k3, IIS6, and SQL Express if that makes a difference. Currently, I 
> have a program running on the server creating an XML file with the
color 
> of the objects as one of the attributes. My flex app routinely reloads 
> this file, but this is cumbersome as it has to reload all the objects 
> and all users of the app don't update simultaneously since the timers 
> all start at differnet times. Looking for some good advice and would be 
> willing to pay for expert help.
> 
> Regards,
> 
> Cameron
>




Re: [flexcoders] Flex Text Selection Problem...

2008-07-12 Thread Toby Ashley
Corey,

There are some potential workarounds which Ive seen, all using similar
techniques to the one found here -
http://labs.hellokeita.com/2008/03/13/textfield-selection-color/

It's not ideal by any means and won't work for all situations, but depending
on what you need, it may be of use.

Cheers
toby

On Sat, Jul 12, 2008 at 12:10 AM, Corey Bray <[EMAIL PROTECTED]> wrote:

>
>Thanks Gordon...that will save me lots of time.
>
> Gordon Smith wrote:
> >
> >
> > Unfortunately, FP9 doesn't support setting the text selection color.
> >
> >
> >
> > Gordon Smith
> >
> > Adobe Flex SDK Team
> >
> >
> >
> > 
> >
> >
> > *From:* flexcoders@yahoogroups.com
> > [mailto:[EMAIL PROTECTED] *On Behalf Of *Corey Bray *Sent:*
> > Friday, July 11, 2008 2:37 PM *To:* flexcoders@yahoogroups.com
> > *Subject:* [flexcoders] Flex Text Selection Problem...
> >
> >
> >
> > Hey,
> >
> > I'm new to the list and was hoping I could get a little help with a
> > problem in flex that is driving me nuts.
> >
> > Here's the problem - when you have a TextInput control whose
> > background color is black and whose text is white, how do you change
> > the color of the selected text so that it's distinguishable from text
> > that is not selected? I have tried changing every color-related
> > property I could find but was not able to change the color of the
> > selection.
> >
> >   > xmlns:mx="http://www.adobe.com/2006/mxml
> > " layout="horizontal"
> > backgroundColor="#00">  TextInput { color: #FF;
> > background-color: #00; backgroundAlpha: 0.0; dropShadowEnabled:
> > false; borderThickness: 2; borderStyle: solid; font-size: 18; }
> > 
> >
> > 
> >
> > 
> >
> > Corey...
> >
> >
>
>
> 
>
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives:
> http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
> Links
>
>
>
>


[flexcoders] Re: GroupingCollection compile error

2008-07-12 Thread Sid Maskit
Somebody else may see something wrong with the code you posted, but
I'm not. It's unclear from your message where the error is occurring.
Based on the error message, it may well be that the error is in the
code above what you posted. 

I would start by pulling out the code you posted, and replacing it
with a very simple visible element, such as a label or text input, and
see if that makes the error go away. If it doesn't go away, you know
the error is somewhere else in your code.

Sid

http://CraftySpace.com

--- In flexcoders@yahoogroups.com, coder3 <[EMAIL PROTECTED]> wrote:
>
> 
> Hi
> 
> I added a mx:GroupingCollection to my mxml. 
> 
> 
>   
>   
>   
> 
> 
> 
> 
> but it gives me a compile error:
> 
> Component declarations are not allowed here. (Note: visual children must
> implement mx.core.IUIComponent)
> 
> what is it? how can i fix it? 
> 
> Thanks!
> 
> C.
> -- 
> View this message in context:
http://www.nabble.com/GroupingCollection-compile-error-tp18410128p18410128.html
> Sent from the FlexCoders mailing list archive at Nabble.com.
>




Re: [flexcoders] Module hell... Flex 3

2008-07-12 Thread Sebastian Mohr
Hi there,

I have the same problem as dbronk mentioned
(see below) in conjunction with Cairngorm 2.2.1.

I always have to dispatch the LoadTestEvent
twice to make the LoadTestCommand calling
the moduleReadyHandler-method. here is the
code:

package com.test
{
   import com.adobe.cairngorm.commands.ICommand;
   import com.adobe.cairngorm.control.CairngormEvent;

   import flash.system.ApplicationDomain;

   import mx.events.ModuleEvent;
   import mx.modules.IModuleInfo;
   import mx.modules.ModuleManager;

   public class LoadTestCommand implements ICommand
   {
  private var moduleInfo:IModuleInfo;

  public function LoadTestCommand()
  {
 moduleInfo = ModuleManager.getModule('TestModule.swf');
 moduleInfo.addEventListener(ModuleEvent.READY, moduleReadyHandler);
 moduleInfo.addEventListener(ModuleEvent.ERROR, moduleErrorHandler);
  }

  public function execute(event:CairngormEvent):void
  {
 moduleInfo.load(ApplicationDomain.currentDomain);
  }

  public function moduleReadyHandler(e:ModuleEvent) : void
  {
 trace('SUCCESS');
  }

  public function moduleErrorHandler(e:ModuleEvent) : void
  {
 trace('ERROR');
  }
   }
}

Is there a solution to dispatch the event only once
to make the Command loading the module?

Thank you,
masu



On 1/28/08, dbronk <[EMAIL PROTECTED]> wrote:
>
> I'm trying to get something very basic to work with modules. I have
> my app and two swf modules (Form1.swf and Form2.swf). Each test
> module simply has a couple TextInput fields. I have also extended
> Module so I can follow what is going on and I will be adding custom
> code later. MyModule extends Module has:
>
> public function MyModule() {
> super();
> trace("Module constructor");
> addEventListener(FlexEvent.INITIALIZE, onInitialize);
> }
>
> protected function onInitialize(event:Event) : void {
> trace("Module.onInit: " + this.toString());
> dispatchEvent(new BaseEvent("moduleLoaded", this, true, true));
> }
>
> Very basic. I want to be notified when the Module is initialized.
>
> When I have the following code inline to a button click which will
> load the module it works fine
>
> var moduleLoader : ModuleLoader = new ModuleLoader();
> moduleLoader.id = moduleName;
> moduleLoader.url = moduleName;
> moduleLoader.loadModule();
> moduleLoader.addEventListener("moduleLoaded", onModuleLoaded);
> moduleStackChild = moduleLoader;
> moduleStack.addChild(moduleStackChild);
> moduleMap.put(moduleName, moduleStackChild);
>
> My onModuleLoaded function gets called.
>
> Now for the issue. If I take this code and place it into a common
> object it no longer works THE FIRST TIME. I have two buttons, one to
> load Form1.swf and the other to load Form2.swf. When this code to
> load the module is in a separate class, it doesn't matter if I click
> button 1 or 2 first. It simply will not work on the first click.
> Second click and beyond work fine. Also, in debug mode, works great
> every time. What happens is that the last thing that runs is the
> loadModule() command. The constructor on MyModule never executes on
> the first execution. Future executions work fine.
>
> I'm hoping I explained this good enough as it is very strange. But I
> definitely want to have this function in my util classes and not have
> to duplicate the code all over the place.
>
> Suggestions?
>
> Thanks,
> Dale
>
> 
>


RE: {Disarmed} RE: [flexcoders] Calling AS3 functions

2008-07-12 Thread Scott
Yes, I did change that already it does say returnEmail on both sides
now.

 

Very interesting...  

 

This would be a better question then...  

 

I've got a login.mxml file which controls the different states the login
can be in.  Each state essentially is another mxml file.  I'm calling a
CFC function to process the login which is in the loginForm.mxml.  This
function has the email address and name as returned by the CFC.  How can
I pull that information out and into the login.mxml file?  So if what
you are saying is that each of the files are their own class, I would
need a way to call that class from another class.

 

I did change that method to be public but still wasn't able to "see" it.
What is the syntax to access an external class from another class?  Do I
need to reference class.function()?

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Alex Harui
Sent: Saturday, July 12, 2008 12:34 AM
To: flexcoders@yahoogroups.com
Subject: {Disarmed} RE: [flexcoders] Calling AS3 functions

 

Each mxml has its own (document) scope.  It essentially defines a class.
A method must be public in order to be accessed from outside the class,
you cannot access protected from outside the class.

 

Your snippet doesn't have id's or show the relationship between the two
classes so it is hard to say why it isn't working. Also, you appear to
be trying to call returnEmail when the snippet only showed a returnName
method.

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Scott
Sent: Friday, July 11, 2008 8:30 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Calling AS3 functions

 

I'm still getting the same error...

 

The class exists in the loginForm.mxml but the mxml code exists in the
login.mxml file.

 

Is there something special I have to do to use the functions that exist
in the other mxml file?

 

Better yet, is there a way to access variables other than setting up a
function in the active script?

 

 Thanks much.

 

---


All AS code needs to be inside the curly braces and you need to
concatenate your static string to the string returned from your function

 

 

--

 

I'm working on a logon class in Flex 3.  I've got a login.mxml which
controls the overall views (logon/register/logout) all in the same box
depending on what state the user is in.

 

In the loginForm.mxml (included in the logon.mxml), I've got a function
called protected returnName():String

 

 

Function I want to call from the loginForm AS3 script:

protected function returnName():String   (I've also tried public in case
it was not available in that area of code)

{

   return this.username.text;

}

 

Snippet from my mxml code:

Xmlns:login="com.ft.views.login.*";

 

...

 



 

   



   



   

  <-
line in question 



   









 

I can't seem to figure out how to reference the method as I get the
error: 1180: Call to a possibly undefined method returnName.

 

I've tried:





Among many others...

 

This is probably pretty simple.  I really appreciate your help.

 


-- 
This message has been scanned for viruses and 
dangerous content by MailScanner  , and is

believed to be clean. 

 


-- 
This message has been scanned for viruses and 
dangerous content by MailScanner  , and is

believed to be clean. 


[flexcoders] PopUpMenu Button item click....

2008-07-12 Thread sudha_bsb
Hi,

I am having strange problem with PopupMenuButton. I am having a
popupmenubutton with submenus as its items.

When I click on the parent menu item( not on the sub menu item), how
can i get the index of the parent menu item  on which it is clicked.
Which event gets triggered for this. The itemClick event is triggered
only when we click on the sub menu item which is in the last hierarchy.

Similarly when i click on the submenu item, i need the index of its
parent menu with respect to popumenu button.

Here is the code...

When I click on Inbox or Calendar menu..i need its index(0 or
1)..Similarly when I click on Personal menu item...I need Inbox
index(its parent menu index.)

Please help



http://www.adobe.com/2006/mxml";
layout="absolute">
   



   
























Thanks,
Sudha.



[flexcoders] Re: Binding for Dynamic Datagrid

2008-07-12 Thread limhy0306
Hi,

I've tried using the suggestion:

myDG.dataProvider={ myData }

But compilation has syntax errors: rightbrace is unexpected.



Also, I've read about the binding regarding changes to the property 
for the ArrayCollection; that we need to use itemUpdated to inform 
about changes to the list.

Basically the myData is a list of a class: MyClass.

public class MyClass
{
   private var _evt:ArrayCollection;

  ... 
}

The var _evt changes in real-time & this changes need to be 
refreshed in the Datagrid.

However, not all instances of MyClass stored in myData changes. 
In this case, I only want to redraw parts of the Datagrid that 
changes only.

Thank you.

Regards.


--- In flexcoders@yahoogroups.com, Simon Bailey <[EMAIL PROTECTED]> wrote:
>
> myDG.dataProvider={ myData }
> 
> On 7 Jul 2008, at 16:26, limhy0306 wrote:
> 
> Hi,
> 
> I've created a custom Dynamic Datagrid component. I would like to
> ask, how can I bind data to this DG?
> 
> My codes:
> 
> // Data to the datagrid. This data is dynamically changing.
> [Bindable]
> public var myData:ArrayCollection();
> 
> public var myDG:MyDG;
> 
> // Called when creationComplete
> private function init()
> {
> myDG = new MyDG();
> myDG.createDataGrid(); // Create the datagrid
> myDG.dataProvider = myData; //Would this bind the data?
> this.addChild(myDG);
> }
> 
> I've noticed that when myData changed, myDG is not updated. In 
fact,
> the set data() function of the ItemRenderer used in myDG is not
> being called when I call myData.refresh().
> 
> Is it the problem that I am not binding myDG correctly?
> 
> Thank you.
>




[flexcoders] 3 tier architecture using adobe flex

2008-07-12 Thread litesh_b321
How to design a 3 tier architecture using adobe flex