RE: [flexcoders] Using a logical AND in property.
Thanks for your help, but I was looking for something closer to what Gordon posted. i.e. && instead of && Im trying to keep interaction designers from writing to much action script code for basic interaction logic. Thanks again. jason -Message d'origine- De : flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] la part de Darren Houle Envoyé : mardi 16 mai 2006 21:47 À : flexcoders@yahoogroups.com Objet : RE: [flexcoders] Using a logical AND in property. Jason, I know this doesn't actually answer your question, but I ran into the same thing recently and found that I was looking at the problem backward. I was trying to set enabled on a Panel based on whether one or more rows were selected in a DataGrid. I tried the same things you did, adding AS code to the Panel's enabled property. I had all kinds of trouble and nothing seemed to work right, until I decided to do things "backwards." Instead of adding code to the enabled property that "watched" or was bound to other values or components, I added an itemClick="panelEnabler();" to the DataGrid. The panelEnabler() function just looks like: public function assignPanelEnabler():void { if(dgAccts.selectedItems.length >= 1) { assign_panel.enabled=true; } else {assign_panel.enabled=false; } } Now, the DataGrid runs the function whenever items are clicked, and the function changes the enabled property for the Panel. Works perfectly, and you don't need to worry about using && inside the enabled property field, you can put all your if...then logical operators in the function script. Darren >From: "Jason Hawryluk" <[EMAIL PROTECTED]> >Reply-To: flexcoders@yahoogroups.com >To: >Subject: RE: [flexcoders] Using a logical AND in property. >Date: Tue, 16 May 2006 15:46:27 +0200 > >I've tried about 10-20 different ways just can't seem to make it work. I >suppose that a function is the only way, but it's unfortunate. Being able >to >compare 1 or more bound values in order to get the result would be very >handy in my particular case. > >Below is the error I get. > >Error: The entity name must immediately follow the '&' in the entity >reference. > > > >On a good note I did get this to work > >{value1.selected==value2.selected} > >but that will only do in certain circumstances. > > >Thanks for your help. I'm still trying to get Flex to do it, if anyone has >any ideas... > >Jason > > >-----Message d'origine- >De : flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] la >part de Michael Schmalle >Envoyé : mardi 16 mai 2006 15:24 >À : flexcoders@yahoogroups.com >Objet : Re: [flexcoders] Using a logical AND in property. > > >Hi, > >I don't even know if you can do it but, did you try using parenthesis ? > >Peace, Mike > > >On 5/16/06, sourcecoderia <[EMAIL PROTECTED]> wrote: >I'm wanting to be able to do something like the below, where the && >operator is used for a locale compare on the Boolean values, however I >keep getting errors with the various methods I've tried. > > > >Where values(1 and 2) are other checkbox controls. > >Any ideas on a good way to do the above. I'm trying to stay away from >script as much as possible for this type of stuff in order to keep it >as simple as possible for the UI designer. > >Thanks > >Jason > > > > > > >-- >Flexcoders Mailing List >FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt >Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com > > > > >YAHOO! GROUPS LINKS > > Visit your group "flexcoders" on the web. > > To unsubscribe from this group, send an email to: > [EMAIL PROTECTED] > > Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. > > > > > > > >-- >What goes up, does come down. > >-- >Flexcoders Mailing List >FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt >Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com > > > > >YAHOO! GROUPS LINKS > > Visit your group "flexcoders" on the web. > > To unsubscribe from this group, send an email to: > [EMAIL PROTECTED] > > Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. > > > > > > >-- >Flexcoders Mailing List >FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt >Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com >Yahoo! Groups Links > > > > > > -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
RE: [flexcoders] Using a logical AND in property.
Perfect Gordon thanks. Never thought of that. I understand the reasoning behind this. Even though it's not easy to read, an interaction designer can learn this faster then vars and functions etc... for basic interaction logic. Jason -Message d'origine- De : flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] la part de Gordon Smith Envoyé : mardi 16 mai 2006 23:19 À : flexcoders@yahoogroups.com Objet : RE: [flexcoders] Using a logical AND in property. <, >, and & are special characters in XML and therefore in MXML. You can't use them in attribute values as is; you have to encode them as the "entities" < > and & Therefore the way to write && in an attribute value is && It's ugly, but if we broke this rule in MXML you wouldn't be able to maniupulate MXML with standard XML tools. - Gordon -Original Message- From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Jason Hawryluk Sent: Tuesday, May 16, 2006 6:46 AM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Using a logical AND in property. I've tried about 10-20 different ways just can't seem to make it work. I suppose that a function is the only way, but it's unfortunate. Being able to compare 1 or more bound values in order to get the result would be very handy in my particular case. Below is the error I get. Error: The entity name must immediately follow the '&' in the entity reference. On a good note I did get this to work {value1.selected==value2.selected} but that will only do in certain circumstances. Thanks for your help. I'm still trying to get Flex to do it, if anyone has any ideas... Jason -Message d'origine- De : flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] la part de Michael Schmalle Envoyé : mardi 16 mai 2006 15:24 À : flexcoders@yahoogroups.com Objet : Re: [flexcoders] Using a logical AND in property. Hi, I don't even know if you can do it but, did you try using parenthesis ? Peace, Mike On 5/16/06, sourcecoderia <[EMAIL PROTECTED]> wrote: I'm wanting to be able to do something like the below, where the && operator is used for a locale compare on the Boolean values, however I keep getting errors with the various methods I've tried. Where values(1 and 2) are other checkbox controls. Any ideas on a good way to do the above. I'm trying to stay away from script as much as possible for this type of stuff in order to keep it as simple as possible for the UI designer. Thanks Jason -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. -- What goes up, does come down. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
RE: [flexcoders] Using a logical AND in property.
<, >, and & are special characters in XML and therefore in MXML. You can't use them in attribute values as is; you have to encode them as the "entities" < > and & Therefore the way to write && in an attribute value is && It's ugly, but if we broke this rule in MXML you wouldn't be able to maniupulate MXML with standard XML tools. - Gordon -Original Message- From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Jason Hawryluk Sent: Tuesday, May 16, 2006 6:46 AM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Using a logical AND in property. I've tried about 10-20 different ways just can't seem to make it work. I suppose that a function is the only way, but it's unfortunate. Being able to compare 1 or more bound values in order to get the result would be very handy in my particular case. Below is the error I get. Error: The entity name must immediately follow the '&' in the entity reference. On a good note I did get this to work {value1.selected==value2.selected} but that will only do in certain circumstances. Thanks for your help. I'm still trying to get Flex to do it, if anyone has any ideas... Jason -Message d'origine- De : flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] la part de Michael Schmalle Envoyé : mardi 16 mai 2006 15:24 À : flexcoders@yahoogroups.com Objet : Re: [flexcoders] Using a logical AND in property. Hi, I don't even know if you can do it but, did you try using parenthesis ? Peace, Mike On 5/16/06, sourcecoderia <[EMAIL PROTECTED]> wrote: I'm wanting to be able to do something like the below, where the && operator is used for a locale compare on the Boolean values, however I keep getting errors with the various methods I've tried. Where values(1 and 2) are other checkbox controls. Any ideas on a good way to do the above. I'm trying to stay away from script as much as possible for this type of stuff in order to keep it as simple as possible for the UI designer. Thanks Jason -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. -- What goes up, does come down. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
RE: [flexcoders] Using a logical AND in property.
Jason, I know this doesn't actually answer your question, but I ran into the same thing recently and found that I was looking at the problem backward. I was trying to set enabled on a Panel based on whether one or more rows were selected in a DataGrid. I tried the same things you did, adding AS code to the Panel's enabled property. I had all kinds of trouble and nothing seemed to work right, until I decided to do things "backwards." Instead of adding code to the enabled property that "watched" or was bound to other values or components, I added an itemClick="panelEnabler();" to the DataGrid. The panelEnabler() function just looks like: public function assignPanelEnabler():void { if(dgAccts.selectedItems.length >= 1) { assign_panel.enabled=true; } else {assign_panel.enabled=false; } } Now, the DataGrid runs the function whenever items are clicked, and the function changes the enabled property for the Panel. Works perfectly, and you don't need to worry about using && inside the enabled property field, you can put all your if...then logical operators in the function script. Darren >From: "Jason Hawryluk" <[EMAIL PROTECTED]> >Reply-To: flexcoders@yahoogroups.com >To: >Subject: RE: [flexcoders] Using a logical AND in property. >Date: Tue, 16 May 2006 15:46:27 +0200 > >I've tried about 10-20 different ways just can't seem to make it work. I >suppose that a function is the only way, but it's unfortunate. Being able >to >compare 1 or more bound values in order to get the result would be very >handy in my particular case. > >Below is the error I get. > >Error: The entity name must immediately follow the '&' in the entity >reference. > > > >On a good note I did get this to work > >{value1.selected==value2.selected} > >but that will only do in certain circumstances. > > >Thanks for your help. I'm still trying to get Flex to do it, if anyone has >any ideas... > >Jason > > >-----Message d'origine- >De : flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] la >part de Michael Schmalle >Envoyé : mardi 16 mai 2006 15:24 >À : flexcoders@yahoogroups.com >Objet : Re: [flexcoders] Using a logical AND in property. > > >Hi, > >I don't even know if you can do it but, did you try using parenthesis ? > >Peace, Mike > > >On 5/16/06, sourcecoderia <[EMAIL PROTECTED]> wrote: >I'm wanting to be able to do something like the below, where the && >operator is used for a locale compare on the Boolean values, however I >keep getting errors with the various methods I've tried. > > > >Where values(1 and 2) are other checkbox controls. > >Any ideas on a good way to do the above. I'm trying to stay away from >script as much as possible for this type of stuff in order to keep it >as simple as possible for the UI designer. > >Thanks > >Jason > > > > > > >-- >Flexcoders Mailing List >FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt >Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com > > > > >YAHOO! GROUPS LINKS > > Visit your group "flexcoders" on the web. > > To unsubscribe from this group, send an email to: > [EMAIL PROTECTED] > > Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. > > > > > > > >-- >What goes up, does come down. > >-- >Flexcoders Mailing List >FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt >Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com > > > > >YAHOO! GROUPS LINKS > > Visit your group "flexcoders" on the web. > > To unsubscribe from this group, send an email to: > [EMAIL PROTECTED] > > Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. > > > > > > >-- >Flexcoders Mailing List >FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt >Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com >Yahoo! Groups Links > > > > > > Yahoo! Groups Sponsor ~--> Protect your PC from spy ware with award winning anti spy technology. It's free. http://us.click.yahoo.com/97bhrC/LGxNAA/yQLSAA/nhFolB/TM ~-> -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 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/
RE: [flexcoders] Using a logical AND in property.
I get the same error. "The entity name must immediately follow the '&' in the entity reference." This should be simple, and for designers way less complicated then writing a function, or dealing with bindable vars etc to do the same kind of stuff. I totally put this in the interaction designer domain space. Thanks for your help. Jason -Message d'origine- De : flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] la part de Manish Jethani Envoyé : mardi 16 mai 2006 16:19 À : flexcoders@yahoogroups.com Objet : Re: [flexcoders] Using a logical AND in property. On 5/16/06, sourcecoderia <[EMAIL PROTECTED]> wrote: > What happens when you do this? -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
Re: [flexcoders] Using a logical AND in property.
On 5/16/06, sourcecoderia <[EMAIL PROTECTED]> wrote: > What happens when you do this? -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
RE: [flexcoders] Using a logical AND in property.
I've tried about 10-20 different ways just can't seem to make it work. I suppose that a function is the only way, but it's unfortunate. Being able to compare 1 or more bound values in order to get the result would be very handy in my particular case. Below is the error I get. Error: The entity name must immediately follow the '&' in the entity reference. On a good note I did get this to work {value1.selected==value2.selected} but that will only do in certain circumstances. Thanks for your help. I'm still trying to get Flex to do it, if anyone has any ideas... Jason -Message d'origine- De : flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] la part de Michael Schmalle Envoyé : mardi 16 mai 2006 15:24 À : flexcoders@yahoogroups.com Objet : Re: [flexcoders] Using a logical AND in property. Hi, I don't even know if you can do it but, did you try using parenthesis ? Peace, Mike On 5/16/06, sourcecoderia <[EMAIL PROTECTED]> wrote: I'm wanting to be able to do something like the below, where the && operator is used for a locale compare on the Boolean values, however I keep getting errors with the various methods I've tried. Where values(1 and 2) are other checkbox controls. Any ideas on a good way to do the above. I'm trying to stay away from script as much as possible for this type of stuff in order to keep it as simple as possible for the UI designer. Thanks Jason -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. -- What goes up, does come down. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com SPONSORED LINKS Web site design development Computer software development Software design and development Macromedia flex Software development best practice YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
Re: [flexcoders] Using a logical AND in property.
Hi, I don't even know if you can do it but, did you try using parenthesis ? Peace, MikeOn 5/16/06, sourcecoderia <[EMAIL PROTECTED]> wrote: I'm wanting to be able to do something like the below, where the && operator is used for a locale compare on the Boolean values, however I keep getting errors with the various methods I've tried. Where values(1 and 2) are other checkbox controls. Any ideas on a good way to do the above. I'm trying to stay away from script as much as possible for this type of stuff in order to keep it as simple as possible for the UI designer. Thanks Jason -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. -- What goes up, does come down. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
[flexcoders] Using a logical AND in property.
I'm wanting to be able to do something like the below, where the && operator is used for a locale compare on the Boolean values, however I keep getting errors with the various methods I've tried. Where values(1 and 2) are other checkbox controls. Any ideas on a good way to do the above. I'm trying to stay away from script as much as possible for this type of stuff in order to keep it as simple as possible for the UI designer. Thanks Jason -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com YAHOO! GROUPS LINKS Visit your group "flexcoders" on the web. To unsubscribe from this group, send an email to: [EMAIL PROTECTED] Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.