No i haven't tried that. How would I do that?
Sorry if this is a really beginner question. On 13 Nov, 12:55, "Vinod M. Jacob" <[EMAIL PROTECTED]> wrote: > i mean storing the resultevent in a collection object and setting it as > dataprovider for chart > > On Thu, Nov 13, 2008 at 6:24 PM, Vinod M. Jacob <[EMAIL PROTECTED]> wrote: > > > Did you try storing the result in a dataprovider? Anyway try refreshing the > > chart dataprovider. > > > On Thu, Nov 13, 2008 at 5:54 PM, [EMAIL PROTECTED] < > > [EMAIL PROTECTED]> wrote: > > >> Hi. > > >> I'm not getting any error messages and i've used Firefox's Firebug to > >> see if the request gets sent which it does and it returns a different > >> dataset. > > >> Doesn't the chart need to be refreshed in anyway to reflect the > >> updated data? > > >> Regards, > >> Alex > > >> On 13 Nov, 11:47, "Vinod M. Jacob" <[EMAIL PROTECTED]> wrote: > >> > This should work.Are you getting any error? > >> > Also you can try to store the result of HTTPService into an collection > >> > object which is declared bindable and assign it as the dataprovider for > >> > chart. > > >> > On Thu, Nov 13, 2008 at 4:25 PM, [EMAIL PROTECTED] < > > >> > [EMAIL PROTECTED]> wrote: > > >> > > Hi. > > >> > > I have a chart the obtains data via a HTTPService. The chart just gets > >> > > values from a MySQL database depending on the month and year selected. > > >> > > In the Flex App I have 2 dropdowns - 1 with the months and 1 with the > >> > > year. > > >> > > What I need to do is to be able to change the year / month hit refresh > >> > > and the chart repopulates with the new data. I can get the request to > >> > > be put through to the server but the chart data won't change. > > >> > > I've included my code below: > > >> > > <?xml version="1.0" encoding="utf-8"?> > >> > > <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" > >> > > layout="absolute" creationComplete="srv.send();"> > >> > > <mx:Script> > >> > > <![CDATA[ > >> > > import flash.events.Event; > >> > > import mx.events.DropdownEvent; > >> > > import mx.controls.Alert; > > >> > > [Bindable] > >> > > public var selected_month:String; > > >> > > [Bindable] > >> > > public var selected_year:String; > > >> > > [Bindable] > >> > > public var contract_id:String; > > >> > > ]]> > >> > > </mx:Script> > >> > > <mx:Style> > >> > > .myBarChartStyle { > >> > > fill:#CDEB8B; > >> > > } > >> > > </mx:Style> > >> > > <mx:HTTPService id="srv" url="http://localhost/qrep/reports/ > >> > > agent_yearly_performance/XML_monthly_generator.php"> > >> > > <mx:request xmlns=""> > >> > > <month>{month.text}</month> > >> > > <year>{year.text}</year> > >> > > </mx:request> > >> > > </mx:HTTPService> > >> > > <mx:Model id="month_source" source="http://localhost/qrep/flex/ > >> > > agent_yearly_overview-debug/months.xml"/> > >> > > <mx:Model id="year_source" source="http://localhost/qrep/flex/ > >> > > agent_yearly_overview-debug/years.xml"/> > >> > > <mx:ComboBox id="month" dataProvider="{month_source.data}" > >> > > labelField="month" x="556" y="10"/> > >> > > <mx:ComboBox id="year" dataProvider="{year_source.data}" > >> > > labelField="year" x="672" y="10"/> > >> > > <mx:Panel title="Monthly Office Overview: {month.text} - > >> > > {year.text}"> > >> > > <mx:BarChart color="#333333" fontSize="9" width="100%" height="100%" > > >> dataProvider="{srv.lastResult.office_monthly_dataset.office_monthly_data}" > >> > > showDataTips="true"> > >> > > <mx:series> > >> > > <mx:BarSeries styleName="myBarChartStyle" xField="totalscore"/> > >> > > </mx:series> > >> > > <mx:verticalAxis> > >> > > <mx:CategoryAxis categoryField="team"/> > >> > > </mx:verticalAxis> > >> > > </mx:BarChart> > >> > > </mx:Panel> > >> > > <mx:Button x="556" y="78" label="Refresh Report" > >> > > id="reportCreateButton" click="month.text; year.text; Alert.show('The > >> > > reporting period has been changes to ' + month.text + ' ' + year.text, > >> > > 'Period Change', mx.controls.Alert.OK); srv.send();"/> > >> > > </mx:Application> > > >> > > I am new to Flex so I would appreciate any help! > > >> > > Thanks. > >> > > Alex- Hide quoted text - > > >> > - Show quoted text - --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Flex India Community" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/flex_india?hl=en -~----------~----~----~----~------~----~------~--~---

