Re: [flexcoders] Flash Player 10 | FileReference.Save
Your download needs to be executed within the function that processes/handles user input... even calling another function will result in the same error. Your only other alternative is to use navigateToUrl... or a servlet call that sends back a stream. I¹m guessing that you have a compelling use case or that auto-download is a requirement typically this kind of behavior is frowned upon by the IT peeps. Would copying the data to the clipboard be an option? Cheers, Rick Winscot On 7/31/09 5:28 PM, "ilikeflex" wrote: > > > > > Hi > > I have scenario in which the user clicks the > > 1.Click the button. > 2.Make a call to server using Remote Object > 3.Show the popup to save the data in file. > > But i came through Flash Player 10 Security Model which says that > > "Error #2176: Certain actions, such as those that display a pop-up window, may > only be invoked upon user interaction, for example by a mouse click or button > press." > > Does it mean that the user has to view the data in the datagrid and then click > save button (User Interaction according to Flash Player 10 Security Model) to > save the data in the file. > > Is there way user can save the data directly after server response. > > Any pointer is highly appreciated > > Thanks > ilikeflex > > > > >>
Re: [flexcoders] xml as dataprovider to datagrid
Single item nodes get turned into objects, not arraycollections. This is a common source of confusion and pain. AFAIK, there is no easy way to deal with this - your code must anticipate the two data types. Guy On 02/08/2009, at 11:34 AM, shizny wrote: Hello, I'm having some really weird issues with populating an advanceddatagrid with xmlList (quoteXMLList) data. Here is my situation. I've got an xmllist that, when looking at one entry (xmlList[0]), has xml looking like this. 20 Now I'm trying to get totalCost as a datafield and for it to show up in a adg column. So I tried something like this variableRowHeight="true" id="quoteDataGrid" dataProvider="{this.quoteXMLList}"> headerText="Total Cost" /> But nothing shows up. So, I changed my dataprovider to this.quoteXMLList.cost and put dataField="totalCost" and it shows up fine. But I can't do that cause I have more info I need to gather for other columns that is in different areas of the xml in the current xmlList. So, can you not put e4x notation in datafield, if not what do I do here? Thanks in advance. Josh
[flexcoders] xml as dataprovider to datagrid
Hello, I'm having some really weird issues with populating an advanceddatagrid with xmlList (quoteXMLList) data. Here is my situation. I've got an xmllist that, when looking at one entry (xmlList[0]), has xml looking like this. 20 Now I'm trying to get totalCost as a datafield and for it to show up in a adg column. So I tried something like this But nothing shows up. So, I changed my dataprovider to this.quoteXMLList.cost and put dataField="totalCost" and it shows up fine. But I can't do that cause I have more info I need to gather for other columns that is in different areas of the xml in the current xmlList. So, can you not put e4x notation in datafield, if not what do I do here? Thanks in advance. Josh
[flexcoders] HSLIDER
Hi I have one requirement in my project.Please help me How can do that. It is releated to HSLIDER in FLEX3. PFB UI image and explanation. Please share me your experience. Hslider Requirement: Year is selected from 2001 to 2005. The visible years in the Line chart are highlighted with blue. The selected years are also displayed underneath the slider (2001, 2005). Thanks in advance, Ramesh
[flexcoders] Re: creation timing on panel component
I didnt include all the code I'll zip it up and email it to you. --- In flexcoders@yahoogroups.com, claudiu ursica wrote: > > From what I see here the button click does not make the call to the http > service. > > The general rule of the thumb is aftter the service call you push the data > into a model which usually updates the view via binding. I always parse data > into array collections or other strong typed objects. Having the items into > an array collection enables you to bind to it if you're using List based > components in the view. However in your case yuou could listed to the > collection change event and do your thing manually. Send me the code via > email and I'll try to debug it. I cannot figure it out from what I see. I > guess you make the call for the data and the result gets back before the > creation complete venet fopr the panel fires. > > C > > > > > > From: Jason B > To: flexcoders@yahoogroups.com > Sent: Saturday, August 1, 2009 9:14:34 PM > Subject: [flexcoders] Re: creation timing on panel component > > > > > is in the main.mxml > > --- In flexcod...@yahoogro ups.com, claudiu ursica wrote: > > > > when are you calling the service? > > > > C > > > > > > > > > > _ _ __ > > From: Jason B > > To: flexcod...@yahoogro ups.com > > Sent: Saturday, August 1, 2009 5:51:26 PM > > Subject: [flexcoders] Re: creation timing on panel component > > > > > > Just so you know if I use this on the component it works fine > > > > > > > > > > > > > > --- In flexcod...@yahoogro ups.com, "Jason B" wrote: > > > > > > Main.mxml > > > -- > > > > > > [Bindable] > > > private var nutritionData: XML; > > > > > > > > > // create breakfast > > > private function createBreakfast( ):void > > > { > > > vsMain.selectedInde x = 1; > > > vsCreateMeals. selectedIndex = 0; > > > plantype = 'Breakfast'; > > > > > > #1009 ERROR HERE BELOW ! > > > pnlCreateBreakfast. meal = nutritionData. > > > breakfast; > > > > > > } > > > > > > > > > > > result="nutritionRe sultHandler( event)" > > > fault="nutritionFau ltHandler( event)" resultFormat= "e4x"/> > > > > > > > > > > > >> > borderStyle= "inset" borderThickness= "2" id="vsCreateMeals" > > > > > > > > > > > > id="pnlCreateBreakf ast" /> > > > > > > > > > > > > - - - - - > > > panelcreatemeal. mxml > > > - > > > > > > > > > borderThicknessLeft ="0" borderThicknessRigh t="0" borderThicknessBott > > > om="0" > > > dropShadowEnabled= "false" > > >horizontalAlign= "center" xmlns:containers= "com.dougmccune. > > > containers. *" title="Select An Item from below" creationPolicy= "all"> > > > > > > > > > > > > > > > > > >> > height="100% " > > > horizontalGap= "1" borderStyle= "inset" backgroundColor= > > > "0xFF" > > > segments="9" reflectionEnabled= "true"/> > > > > > > > > > > > >> > click="parentApplic ation.vsCreateMe als.selectedInde x=1;"/> > > > > > > > > > > > > > > > > > > - > > > panelcreatemealitem .mxml > > > - > > > > > > http://www.adobe. com/2006/ mxml" width="310" > > > height="320" > > >title="{mealDetails .title}" horizontalAlign= "center" creationPolicy= > > > "all"> > > > > > > > > > > > > [Event(name= "addToMeal" )] > > > [Event(name= "learnAboutThis" )] > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > --- In flexcod...@yahoogro ups.com, claudiu ursica wrote: > > > > > > > > Quick and really dirty... > > > > wrap them inside a try catch block... but then I can't believe I just > > > > said that... Share some more code and I'll come up with something more > > > > engineering like... > > > > > > > > C > > > > > > > > > > > > > > > > > > > > _ _ __ > > > > From: Jason B > > > > To: flexcod...@yahoogro ups.com > > > > Sent: Saturday, August 1, 2009 5:25:33 PM > > > > Subject: [flexcoders] creation timing on panel component > > > > > > > > > > > > > > > > I'm calling a httpservice which I populate into this nutritionData > > > > variable, I'm using a panel component to reuse it, and when I call the > > > > #SETTER below it throws a 1009 error, I was wondering if the panel is > > > > not yet created, if thats the case h
Re: [flexcoders] Re: creation timing on panel component
>From what I see here the button click does not make the call to the http >service. The general rule of the thumb is aftter the service call you push the data into a model which usually updates the view via binding. I always parse data into array collections or other strong typed objects. Having the items into an array collection enables you to bind to it if you're using List based components in the view. However in your case yuou could listed to the collection change event and do your thing manually. Send me the code via email and I'll try to debug it. I cannot figure it out from what I see. I guess you make the call for the data and the result gets back before the creation complete venet fopr the panel fires. C From: Jason B To: flexcoders@yahoogroups.com Sent: Saturday, August 1, 2009 9:14:34 PM Subject: [flexcoders] Re: creation timing on panel component is in the main.mxml --- In flexcod...@yahoogro ups.com, claudiu ursica wrote: > > when are you calling the service? > > C > > > > > _ _ __ > From: Jason B > To: flexcod...@yahoogro ups.com > Sent: Saturday, August 1, 2009 5:51:26 PM > Subject: [flexcoders] Re: creation timing on panel component > > > Just so you know if I use this on the component it works fine > > > > > > > --- In flexcod...@yahoogro ups.com, "Jason B" wrote: > > > > Main.mxml > > -- > > > > [Bindable] > > private var nutritionData: XML; > > > > > > // create breakfast > > private function createBreakfast( ):void > > { > > vsMain.selectedInde x = 1; > > vsCreateMeals. selectedIndex = 0; > > plantype = 'Breakfast'; > > > > #1009 ERROR HERE BELOW ! > > pnlCreateBreakfast. meal = nutritionData. > > breakfast; > > > > } > > > > > > > result="nutritionRe sultHandler( event)" > > fault="nutritionFau ltHandler( event)" resultFormat= "e4x"/> > > > > > > > > > borderStyle= "inset" borderThickness= "2" id="vsCreateMeals" > > > > > > > > id="pnlCreateBreakf ast" /> > > > > > > > > - - - - - > > panelcreatemeal. mxml > > - > > > > > > borderThicknessLeft ="0" borderThicknessRigh t="0" borderThicknessBott > > om="0" > > dropShadowEnabled= "false" > > horizontalAlign= "center" xmlns:containers= "com.dougmccune. > > containers. *" title="Select An Item from below" creationPolicy= "all"> > > > > > > > > > > > > > height="100% " > > horizontalGap= "1" borderStyle= "inset" backgroundColor= > > "0xFF" > > segments="9" reflectionEnabled= "true"/> > > > > > > > > > click="parentApplic ation.vsCreateMe als.selectedInde x=1;"/> > > > > > > > > > > > > - > > panelcreatemealitem .mxml > > - > > > > http://www.adobe. com/2006/ mxml" width="310" > > height="320" > > title="{mealDetails .title}" horizontalAlign= "center" creationPolicy= > > "all"> > > > > > > > > [Event(name= "addToMeal" )] > > [Event(name= "learnAboutThis" )] > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > --- In flexcod...@yahoogro ups.com, claudiu ursica wrote: > > > > > > Quick and really dirty... > > > wrap them inside a try catch block... but then I can't believe I just > > > said that... Share some more code and I'll come up with something more > > > engineering like... > > > > > > C > > > > > > > > > > > > > > > _ _ __ > > > From: Jason B > > > To: flexcod...@yahoogro ups.com > > > Sent: Saturday, August 1, 2009 5:25:33 PM > > > Subject: [flexcoders] creation timing on panel component > > > > > > > > > > > > I'm calling a httpservice which I populate into this nutritionData > > > variable, I'm using a panel component to reuse it, and when I call the > > > #SETTER below it throws a 1009 error, I was wondering if the panel is > > > not yet created, if thats the case how can i wait until the panel is > > > created? > > > > > > [Bindable] > > > private var nutritionData: XML; > > > > > > #SETTER > > > pnlCreateBreakfast. meal = nutritionData. breakfast; > > > > > >
[flexcoders] Re: creation timing on panel component
is in the main.mxml --- In flexcoders@yahoogroups.com, claudiu ursica wrote: > > when are you calling the service? > > C > > > > > > From: Jason B > To: flexcoders@yahoogroups.com > Sent: Saturday, August 1, 2009 5:51:26 PM > Subject: [flexcoders] Re: creation timing on panel component > > > Just so you know if I use this on the component it works fine > > > > > > > --- In flexcod...@yahoogro ups.com, "Jason B" wrote: > > > > Main.mxml > > -- > > > > [Bindable] > > private var nutritionData: XML; > > > > > > // create breakfast > > private function createBreakfast( ):void > > { > > vsMain.selectedInde x = 1; > > vsCreateMeals. selectedIndex = 0; > > plantype = 'Breakfast'; > > > > #1009 ERROR HERE BELOW ! > > pnlCreateBreakfast. meal = nutritionData. > > breakfast; > > > > } > > > > > > > result="nutritionRe sultHandler( event)" > > fault="nutritionFau ltHandler( event)" resultFormat= "e4x"/> > > > > > > > > > borderStyle= "inset" borderThickness= "2" id="vsCreateMeals" > > > > > > > > id="pnlCreateBreakf ast" /> > > > > > > > > - - - - - > > panelcreatemeal. mxml > > - > > > > http://www.adobe. com/2006/ mxml" width="100%" > > height="390" > > borderThicknessLeft ="0" borderThicknessRigh t="0" borderThicknessBott > > om="0" > > dropShadowEnabled= "false" > > horizontalAlign= "center" xmlns:containers= "com.dougmccune. > > containers. *" title="Select An Item from below" creationPolicy= "all"> > > > > > > > > > > > > > height="100% " > > horizontalGap= "1" borderStyle= "inset" backgroundColor= > > "0xFF" > > segments="9" reflectionEnabled= "true"/> > > > > > > > > > click="parentApplic ation.vsCreateMe als.selectedInde x=1;"/> > > > > > > > > > > > > - > > panelcreatemealitem .mxml > > - > > > > http://www.adobe. com/2006/ mxml" width="310" > > height="320" > > title="{mealDetails .title}" horizontalAlign= "center" creationPolicy= > > "all"> > > > > > > > > [Event(name= "addToMeal" )] > > [Event(name= "learnAboutThis" )] > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > --- In flexcod...@yahoogro ups.com, claudiu ursica wrote: > > > > > > Quick and really dirty... > > > wrap them inside a try catch block... but then I can't believe I just > > > said that... Share some more code and I'll come up with something more > > > engineering like... > > > > > > C > > > > > > > > > > > > > > > _ _ __ > > > From: Jason B > > > To: flexcod...@yahoogro ups.com > > > Sent: Saturday, August 1, 2009 5:25:33 PM > > > Subject: [flexcoders] creation timing on panel component > > > > > > > > > > > > I'm calling a httpservice which I populate into this nutritionData > > > variable, I'm using a panel component to reuse it, and when I call the > > > #SETTER below it throws a 1009 error, I was wondering if the panel is > > > not yet created, if thats the case how can i wait until the panel is > > > created? > > > > > > [Bindable] > > > private var nutritionData: XML; > > > > > > #SETTER > > > pnlCreateBreakfast. meal = nutritionData. breakfast; > > > > > >
[flexcoders] Flex 3 Debugger hanging
I have used the debugger in Flex Builder 3 Professional happily on my MacPro for a while. Recently I tried to profile our app and had some issues and now everytime I try to just use the debugger it shows in the console "[SWF] Users:me:workspaces:eclipse-project-workspace:.metadata:.plugins:com.adobe.flash.profiler:ProfilerAgent.swf - 17,508 bytes after decompression [SWF] Users:me:work:olympus:trunk:components:project:bin-debug:Blah.swf - 1,703,941 bytes after decompression" Like its trying to run the profiller also and 99% of the time it hangs now. Any ideas? - Todd
Re: [flexcoders] Re: creation timing on panel component
when are you calling the service? C From: Jason B To: flexcoders@yahoogroups.com Sent: Saturday, August 1, 2009 5:51:26 PM Subject: [flexcoders] Re: creation timing on panel component Just so you know if I use this on the component it works fine --- In flexcod...@yahoogro ups.com, "Jason B" wrote: > > Main.mxml > -- > > [Bindable] > private var nutritionData: XML; > > > // create breakfast > private function createBreakfast( ):void > { > vsMain.selectedInde x = 1; > vsCreateMeals. selectedIndex = 0; > plantype = 'Breakfast'; > > #1009 ERROR HERE BELOW ! > pnlCreateBreakfast. meal = nutritionData. > breakfast; > > } > > >result="nutritionRe sultHandler( event)" > fault="nutritionFau ltHandler( event)" resultFormat= "e4x"/> > > > >borderStyle= "inset" borderThickness= "2" id="vsCreateMeals" > > > > id="pnlCreateBreakf ast" /> > > > > - - - - - > panelcreatemeal. mxml > - > > http://www.adobe. com/2006/ mxml" width="100%" > height="390" > borderThicknessLeft ="0" borderThicknessRigh t="0" borderThicknessBott > om="0" > dropShadowEnabled= "false" >horizontalAlign= "center" xmlns:containers= "com.dougmccune. > containers. *" title="Select An Item from below" creationPolicy= "all"> > > > > > >height="100% " > horizontalGap= "1" borderStyle= "inset" backgroundColor= > "0xFF" > segments="9" reflectionEnabled= "true"/> > > > >click="parentApplic ation.vsCreateMe als.selectedInde x=1;"/> > > > > > > - > panelcreatemealitem .mxml > - > > http://www.adobe. com/2006/ mxml" width="310" > height="320" >title="{mealDetails .title}" horizontalAlign= "center" creationPolicy= > "all"> > > > > [Event(name= "addToMeal" )] > [Event(name= "learnAboutThis" )] > > > > > > > > > > > > > > > > > > > > > > > > > > > > --- In flexcod...@yahoogro ups.com, claudiu ursica wrote: > > > > Quick and really dirty... > > wrap them inside a try catch block... but then I can't believe I just said > > that... Share some more code and I'll come up with something more > > engineering like... > > > > C > > > > > > > > > > _ _ __ > > From: Jason B > > To: flexcod...@yahoogro ups.com > > Sent: Saturday, August 1, 2009 5:25:33 PM > > Subject: [flexcoders] creation timing on panel component > > > > > > > > I'm calling a httpservice which I populate into this nutritionData > > variable, I'm using a panel component to reuse it, and when I call the > > #SETTER below it throws a 1009 error, I was wondering if the panel is > > not yet created, if thats the case how can i wait until the panel is > > created? > > > > [Bindable] > > private var nutritionData: XML; > > > > #SETTER > > pnlCreateBreakfast. meal = nutritionData. breakfast; > > >
[flexcoders] Re: creation timing on panel component
Just so you know if I use this on the component it works fine --- In flexcoders@yahoogroups.com, "Jason B" wrote: > > Main.mxml > -- > > [Bindable] > private var nutritionData:XML; > > > // create breakfast > private function createBreakfast():void > { > vsMain.selectedIndex = 1; > vsCreateMeals.selectedIndex = 0; > plantype = 'Breakfast'; > > #1009 ERROR HERE BELOW ! > pnlCreateBreakfast.meal = > nutritionData.breakfast; > > } > > >result="nutritionResultHandler(event)" > fault="nutritionFaultHandler(event)" resultFormat="e4x"/> > > > >borderStyle="inset" borderThickness="2" id="vsCreateMeals"> > > > id="pnlCreateBreakfast" /> > > > > - > panelcreatemeal.mxml > - > > http://www.adobe.com/2006/mxml"; width="100%" height="390" > borderThicknessLeft="0" borderThicknessRight="0" > borderThicknessBottom="0" > dropShadowEnabled="false" >horizontalAlign="center" > xmlns:containers="com.dougmccune.containers.*" title="Select An Item from > below" creationPolicy="all"> > > > > > >height="100%" > horizontalGap="1" borderStyle="inset" > backgroundColor="0xFF" > segments="9" reflectionEnabled="true"/> > > >click="parentApplication.vsCreateMeals.selectedIndex=0;"/> >click="parentApplication.vsCreateMeals.selectedIndex=1;"/> >click="parentApplication.vsCreateMeals.selectedIndex=2;"/> > > > > > - > panelcreatemealitem.mxml > - > > http://www.adobe.com/2006/mxml"; width="310" height="320" >title="{mealDetails.title}" horizontalAlign="center" > creationPolicy="all"> > > > > [Event(name="addToMeal")] > [Event(name="learnAboutThis")] > > > > > > > > > > > > > > > > > > > > > > > > > > > > --- In flexcoders@yahoogroups.com, claudiu ursica wrote: > > > > Quick and really dirty... > > wrap them inside a try catch block... but then I can't believe I just said > > that... Share some more code and I'll come up with something more > > engineering like... > > > > C > > > > > > > > > > > > From: Jason B > > To: flexcoders@yahoogroups.com > > Sent: Saturday, August 1, 2009 5:25:33 PM > > Subject: [flexcoders] creation timing on panel component > > > > > > > > I'm calling a httpservice which I populate into this nutritionData > > variable, I'm using a panel component to reuse it, and when I call the > > #SETTER below it throws a 1009 error, I was wondering if the panel is > > not yet created, if thats the case how can i wait until the panel is > > created? > > > > [Bindable] > > private var nutritionData: XML; > > > > #SETTER > > pnlCreateBreakfast. meal = nutritionData. breakfast; > > >
[flexcoders] Re: creation timing on panel component
Main.mxml -- [Bindable] private var nutritionData:XML; // create breakfast private function createBreakfast():void { vsMain.selectedIndex = 1; vsCreateMeals.selectedIndex = 0; plantype = 'Breakfast'; #1009 ERROR HERE BELOW ! pnlCreateBreakfast.meal = nutritionData.breakfast; } - panelcreatemeal.mxml - http://www.adobe.com/2006/mxml"; width="100%" height="390" borderThicknessLeft="0" borderThicknessRight="0" borderThicknessBottom="0" dropShadowEnabled="false" horizontalAlign="center" xmlns:containers="com.dougmccune.containers.*" title="Select An Item from below" creationPolicy="all"> - panelcreatemealitem.mxml - http://www.adobe.com/2006/mxml"; width="310" height="320" title="{mealDetails.title}" horizontalAlign="center" creationPolicy="all"> [Event(name="addToMeal")] [Event(name="learnAboutThis")] --- In flexcoders@yahoogroups.com, claudiu ursica wrote: > > Quick and really dirty... > wrap them inside a try catch block... but then I can't believe I just said > that... Share some more code and I'll come up with something more engineering > like... > > C > > > > > > From: Jason B > To: flexcoders@yahoogroups.com > Sent: Saturday, August 1, 2009 5:25:33 PM > Subject: [flexcoders] creation timing on panel component > > > > I'm calling a httpservice which I populate into this nutritionData > variable, I'm using a panel component to reuse it, and when I call the > #SETTER below it throws a 1009 error, I was wondering if the panel is > not yet created, if thats the case how can i wait until the panel is > created? > > [Bindable] > private var nutritionData: XML; > > #SETTER > pnlCreateBreakfast. meal = nutritionData. breakfast; >
Re: [flexcoders] creation timing on panel component
Quick and really dirty... wrap them inside a try catch block... but then I can't believe I just said that... Share some more code and I'll come up with something more engineering like... C From: Jason B To: flexcoders@yahoogroups.com Sent: Saturday, August 1, 2009 5:25:33 PM Subject: [flexcoders] creation timing on panel component I'm calling a httpservice which I populate into this nutritionData variable, I'm using a panel component to reuse it, and when I call the #SETTER below it throws a 1009 error, I was wondering if the panel is not yet created, if thats the case how can i wait until the panel is created? [Bindable] private var nutritionData: XML; #SETTER pnlCreateBreakfast. meal = nutritionData. breakfast;
[flexcoders] creation timing on panel component
I'm calling a httpservice which I populate into this nutritionData variable, I'm using a panel component to reuse it, and when I call the #SETTER below it throws a 1009 error, I was wondering if the panel is not yet created, if thats the case how can i wait until the panel is created? [Bindable] private var nutritionData:XML; #SETTER pnlCreateBreakfast.meal = nutritionData.breakfast;
[flexcoders] Unwanted web services prompt
This is not really a Flex-specific question, but its driving me crazy and I haven't found an answer online. In logging into a 3rd party web service (twitter actually) I get a windows or explorer-generated popup login prompt if the first login fails. Anyone seen this and know how to disable it?