Here's a small example :) Greetz Erik _____
From: Robert Brueckmann [mailto:[EMAIL PROTECTED] Sent: donderdag 3 maart 2005 17:14 To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Theory and Practice: Mixing AS2.0 in MXML Erik...if at all possible, could you give an example, like attach a sample MXML file and the accompanying AS file you created that extends that MXML file? Just want to get a feel for this...and how you reference things and what have you. Thanks! Robert L. Brueckmann Web Developer Merlin Securities, LLC 595 Madison Avenue New York, NY 10022 p: 212.822.4821 f: 212.822.4820 _____ From: Erik Westra [mailto:[EMAIL PROTECTED] Sent: Thursday, March 03, 2005 10:30 AM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Theory and Practice: Mixing AS2.0 in MXML That was my initial approach too, but eventualy it was easier to track bugs and 'mis-references' since i extended the component i was accessing. Now i get an error when i try to reference a textfield that isnt there. Another thing that is a pro for this kind of approach, is that the mxml file doesnt have to know wich method to call in the helper class. Greetz Erik _____ From: Dimitrios Gianninas [mailto:[EMAIL PROTECTED] Sent: donderdag 3 maart 2005 16:22 To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Theory and Practice: Mixing AS2.0 in MXML I tend to put such code in the corresponding ViewHelper class, so every view (MXML file) has a corresponding ViewHelper class. See sample below: Inboxes.mxml <mx:Box> ... <vw:InboxesViewHelper id="inboxesHelper" view="{this}"/> ... <mx:List id="inboxList" width="165" height="100%" labelField="name" vScrollPolicy="auto" change="inboxesHelper.doLoadInbox(inboxList.selectedItem.id)" /> ... </mx:Box> Jimmy Gianninas Software Developer - Optimal Payments Inc. _____ This message contains information from Merlin Securities, LLC, or from one of its affiliates, that may be confidential and privileged. If you are not an intended recipient, please refrain from any disclosure, copying, distribution or use of this information and note that such actions are prohibited. If you have received this transmission in error, please notify the sender immediately by telephone or by replying to this transmission. Merlin Securities, LLC is a registered broker-dealer. Services offered through Merlin Securities, LLC are not insured by the FDIC or any other Federal Government Agency, are not deposits of or guaranteed by Merlin Securities, LLC and may lose value. Nothing in this communication shall constitute a solicitation or recommendation to buy or sell a particular security. Yahoo! Groups Sponsor ADVERTISEMENT click here <http://us.ard.yahoo.com/SIG=129a9hgd3/M=298184.6018725.7038619.3001176/ D=groups/S=1705007207:HM/EXP=1109952906/A=2593423/R=0/SIG=11el9gslf/*htt p://www.netflix.com/Default?mqso=60190075> <http://us.adserver.yahoo.com/l?M=298184.6018725.7038619.3001176/D=group s/S=:HM/A=2593423/rand=145597728> _____ 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] <mailto:[EMAIL PROTECTED]> * Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service <http://docs.yahoo.com/info/terms/> . ------_=_NextPart_002_01C520A0.D78E4373 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML xmlns:eXclaimer = "http://www.exclaimer.co.uk" xmlns:msxsl = "urn:schemas-microsoft-com:xslt" xmlns:exc = "http://www.exclaimer.co.uk/rtf"><HEAD> <META http-equiv=Content-Type content="text/html; charset=us-ascii"> <META content="MSHTML 6.00.2800.1491" name=GENERATOR><!--[if !mso]> <STYLE>v\:* { BEHAVIOR: url(#default#VML) } o\:* { BEHAVIOR: url(#default#VML) } w\:* { BEHAVIOR: url(#default#VML) } .shape { BEHAVIOR: url(#default#VML) } </STYLE> <![endif]--><O:SMARTTAGTYPE name="PostalCode" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="State" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="City" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="place" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="Street" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="address" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="PersonName" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><!--[if !mso]> <STYLE>st1\:* { BEHAVIOR: url(#default#ieooui) } </STYLE> <![endif]--> <STYLE>@font-face { font-family: Wingdings; } @font-face { font-family: Tahoma; } @font-face { font-family: Verdana; } @font-face { font-family: Franklin Gothic Book; } @font-face { font-family: Century Gothic; } @page Section1 {size: 8.5in 11.0in; margin: 1.0in 1.25in 1.0in 1.25in; } P.MsoNormal { FONT-SIZE: 12pt; MARGIN: 0in 0in 0pt; FONT-FAMILY: "Times New Roman" } LI.MsoNormal { FONT-SIZE: 12pt; MARGIN: 0in 0in 0pt; FONT-FAMILY: "Times New Roman" } DIV.MsoNormal { FONT-SIZE: 12pt; MARGIN: 0in 0in 0pt; FONT-FAMILY: "Times New Roman" } A:link { COLOR: blue; TEXT-DECORATION: underline } SPAN.MsoHyperlink { COLOR: blue; TEXT-DECORATION: underline } A:visited { COLOR: blue; TEXT-DECORATION: underline } SPAN.MsoHyperlinkFollowed { COLOR: blue; TEXT-DECORATION: underline } P { FONT-SIZE: 12pt; MARGIN-LEFT: 0in; MARGIN-RIGHT: 0in; FONT-FAMILY: "Times New Roman"; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto } TT { FONT-FAMILY: "Courier New" } SPAN.EmailStyle19 { COLOR: navy; FONT-FAMILY: Arial; mso-style-type: personal } SPAN.EmailStyle21 { COLOR: navy; FONT-FAMILY: Arial; mso-style-type: personal-reply } DIV.Section1 { page: Section1 } OL { MARGIN-BOTTOM: 0in } UL { MARGIN-BOTTOM: 0in } </STYLE> <O:SMARTTAGTYPE name="PostalCode" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="State" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="City" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="place" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="Street" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="address" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /><O:SMARTTAGTYPE name="PersonName" namespaceuri="urn:schemas-microsoft-com:office:smarttags" /></HEAD> <BODY lang=EN-US vLink=blue link=blue> <DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN class=513005909-04032005>Here's a small example :)</SPAN></FONT></DIV> <DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN class=513005909-04032005></SPAN></FONT> </DIV> <DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN class=513005909-04032005></SPAN></FONT> </DIV> <DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN class=513005909-04032005>Greetz Erik</SPAN></FONT></DIV><BR> <DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left> <HR tabIndex=-1> <FONT face=Tahoma size=2><B>From:</B> Robert Brueckmann [mailto:[EMAIL PROTECTED] <BR><B>Sent:</B> donderdag 3 maart 2005 17:14<BR><B>To:</B> flexcoders@yahoogroups.com<BR><B>Subject:</B> RE: [flexcoders] Theory and Practice: Mixing AS2.0 in MXML<BR></FONT><BR></DIV> <DIV></DIV> <DIV> <DIV class=Section1> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial">Erik…if atall possible, could you give an example, like attach a sample MXML file and the accompanying AS file you created that extends that MXML file? Just want to get a feel for this…and how you reference things and what have you.<O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial">Thanks!<O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial"><O:P></O:P></SPAN></FONT></P> <DIV> <P class=MsoNormal><STRONG><B><FONT face=Verdana color=navy size=1><SPAN style="FONT-SIZE: 7.5pt; COLOR: navy; FONT-FAMILY: Verdana">Robert L. Brueckmann</SPAN></FONT></B></STRONG><FONT color=navy><SPAN style="COLOR: navy"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><STRONG><B><FONT face=Verdana color=navy size=1><SPAN style="FONT-SIZE: 7.5pt; COLOR: navy; FONT-FAMILY: Verdana">Web Developer</SPAN></FONT></B></STRONG><FONT color=navy><SPAN style="COLOR: navy"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><STRONG><B><FONT face=Verdana color=navy size=1><SPAN style="FONT-SIZE: 7.5pt; COLOR: navy; FONT-FAMILY: Verdana">Merlin Securities, LLC</SPAN></FONT></B></STRONG><FONT color=navy><SPAN style="COLOR: navy"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><ST1:STREET w:st="on"><ST1:ADDRESS w:st="on"><FONT face=Verdana color=navy size=1><SPAN style="FONT-SIZE: 7.5pt; COLOR: navy; FONT-FAMILY: Verdana">595 Madison Avenue</SPAN></FONT></ST1:ADDRESS></ST1:STREET><FONT color=navy><SPAN style="COLOR: navy"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><ST1:PLACE w:st="on"><ST1:CITY w:st="on"><FONT face=Verdana color=navy size=1><SPAN style="FONT-SIZE: 7.5pt; COLOR: navy; FONT-FAMILY: Verdana">New York</SPAN></FONT></ST1:CITY><FONT face=Verdana color=navy size=1><SPAN style="FONT-SIZE: 7.5pt; COLOR: navy; FONT-FAMILY: Verdana">, <ST1:STATE w:st="on">NY</ST1:STATE> <ST1:POSTALCODE w:st="on">10022</ST1:POSTALCODE></SPAN></FONT></ST1:PLACE><FONT color=navy><SPAN style="COLOR: navy"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face=Verdana color=navy size=1><SPAN style="FONT-SIZE: 7.5pt; COLOR: navy; FONT-FAMILY: Verdana">p: 212.822.4821<BR>f: 212.822.4820</SPAN></FONT><O:P></O:P></P></DIV> <DIV> <DIV class=MsoNormal style="TEXT-ALIGN: center" align=center><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> <HR tabIndex=-1 align=center width="100%" SIZE=2> </SPAN></FONT></DIV> <P class=MsoNormal><B><FONT face=Tahoma size=2><SPAN style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">From:</SPAN></FONT></B><FONT face=Tahoma size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma"> Erik Westra [mailto:[EMAIL PROTECTED] <BR><B><SPAN style="FONT-WEIGHT: bold">Sent:</SPAN></B> Thursday, March 03, 2005 10:30 AM<BR><B><SPAN style="FONT-WEIGHT: bold">To:</SPAN></B> <ST1:PERSONNAME w:st="on">flexcoders@yahoogroups.com</ST1:PERSONNAME><BR><B><SPAN style="FONT-WEIGHT: bold">Subject:</SPAN></B> RE: [flexcoders] Theory and Practice: Mixing AS2.0 in MXML</SPAN></FONT><O:P></O:P></P></DIV> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial">That was my initial approach too, but eventualy it was easier to track bugs and 'mis-references' since i extended the component i was accessing. Now i get an error when i try to reference a textfield that isnt there. Another thing that is a pro for thiskind of approach, is that the mxml file doesnt have to know wich method to call in the helper class.</SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial">Greetz Erik</SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><O:P></O:P></SPAN></FONT></P> <DIV class=MsoNormal style="TEXT-ALIGN: center" align=center><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> <HR tabIndex=-1 align=center width="100%" SIZE=2> </SPAN></FONT></DIV> <P class=MsoNormal style="MARGIN-BOTTOM: 12pt"><B><FONT face=Tahoma size=2><SPAN style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">From:</SPAN></FONT></B><FONT face=Tahoma size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma"> Dimitrios Gianninas [mailto:[EMAIL PROTECTED] <BR><B><SPAN style="FONT-WEIGHT: bold">Sent:</SPAN></B> donderdag 3 maart 2005 16:22<BR><B><SPAN style="FONT-WEIGHT: bold">To:</SPAN></B> <ST1:PERSONNAME w:st="on">flexcoders@yahoogroups.com</ST1:PERSONNAME><BR><B><SPAN style="FONT-WEIGHT: bold">Subject:</SPAN></B> RE: [flexcoders] Theory and Practice: Mixing AS2.0 in MXML</SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Franklin Gothic Book" color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Franklin Gothic Book'">I tend to put such code in the corresponding ViewHelper class, so every view (MXML file) has a corresponding ViewHelper class. See sample below:</SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face="Franklin Gothic Book" color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Franklin Gothic Book'">Inboxes.mxml</SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Franklin Gothic Book" color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Franklin Gothic Book'"><mx:Box></SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT><FONT face="Franklin Gothic Book" color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Franklin Gothic Book'">...</SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT><FONT face="Franklin Gothic Book" color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Franklin Gothic Book'"><vw:InboxesViewHelper id="inboxesHelper" view="{this}"/></SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Franklin Gothic Book" color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Franklin Gothic Book'"> ...</SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT><FONT face="Franklin Gothic Book" color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Franklin Gothic Book'"><mx:List id="inboxList" width="165" height="100%" labelField="name"<BR> vScrollPolicy="auto" change="inboxesHelper.doLoadInbox(inboxList.selectedItem.id)" /></SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT><FONT face="Franklin Gothic Book" color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Franklin Gothic Book'"> ...</SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Franklin Gothic Book" color=blue size=2><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Franklin Gothic Book'"></mx:Box></SPAN></FONT><O:P></O:P></P> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><O:P></O:P></SPAN></FONT></P> <P class=MsoNormal><STRONG><B><FONT face="Century Gothic" color=#006595 size=2><SPAN style="FONT-SIZE: 10pt; COLOR: #006595; FONT-FAMILY: 'Century Gothic'">Jimmy Gianninas</SPAN></FONT></B></STRONG><O:P></O:P></P> <P class=MsoNormal><STRONG><B><FONT face="Century Gothic" color=gray size=2><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Century Gothic'">Software Developer -</SPAN></FONT></B></STRONG><STRONG><B><FONT face="Century Gothic" color=silver size=2><SPAN style="FONT-SIZE: 10pt; COLOR: silver; FONT-FAMILY: 'Century Gothic'"> </SPAN></FONT></B></STRONG><STRONG><B><FONT face="Century Gothic" color=gray size=2><SPAN style="FONT-SIZE: 10pt; COLOR: gray; FONT-FAMILY: 'Century Gothic'">Optimal Payments Inc.</SPAN></FONT></B></STRONG><O:P></O:P></P> <DIV> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><O:P></O:P></SPAN></FONT></P></DIV> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><BR><BR><O:P></O:P></SPAN></FONT></P></DIV> <DIV> </DIV> <DIV class=MsoNormal style="FONT-SIZE: 9pt; MARGIN: 0in 0in 0pt; FONT-FAMILY: Courier New; TEXT-ALIGN: center" align=center><SPAN style="FONT-SIZE: 10pt"> <HR align=center width="100%" SIZE=2> </SPAN></DIV> <DIV style="FONT-SIZE: 9pt; FONT-FAMILY: Courier New"><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Times New Roman'; mso-fareast-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"><FONT color=gray>This message contains information from Merlin Securities,LLC, or from one of its affiliates, that may be confidential and privileged. If you are not an intended recipient, please refrain from any disclosure, copying, distribution or use of this information and note that such actions are prohibited. If you have received this transmission in error, please notify the sender immediately by telephone or by replying to this transmission.</FONT></SPAN></DIV> <DIV style="FONT-SIZE: 9pt; FONT-FAMILY: Courier New"><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Times New Roman'; mso-fareast-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"></SPAN><FONT color=gray size=2></FONT> </DIV> <DIV style="FONT-SIZE: 9pt; FONT-FAMILY: Courier New"><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Times New Roman'; mso-fareast-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"><FONT color=gray>Merlin Securities, LLC is a registered broker-dealer. Services offered through Merlin Securities, LLC are not insured by the FDIC or any other Federal Government Agency, are not deposits of or guaranteed by Merlin Securities, LLC and may lose value. Nothing in this communication shall constitute a solicitation or recommendation to buy or sell a particular security.</FONT></SPAN></DIV><BR></DIV></BODY></HTML> ------_=_NextPart_002_01C520A0.D78E4373--
bin3wpN3gK6cT.bin
Description: MyClassVisual.mxml
binPY27U6Hw9N.bin
Description: MyClass.as
binIXygcoKw8K.bin
Description: test.mxml