3 Replies Latest reply on Jan 7, 2009 11:54 PM by Richard_Abbott

    Refreshing xml data in flex

    Piyush Giri
      Can someone suggest me a method, how to refresh the xml data coming through a rss feed in a datagrid in the flex application.
      Thanks in advance!!!
        • 1. Re: Refreshing xml data in flex
          ntsiii Level 3
          That is not enough information to work with. "refresh" has too many meanings.
          • 2. Re: Refreshing xml data in flex
            Piyush Giri Level 1
            Sorry for unclear information.
            Refresh here means that whenever any changes done in the XML source file at the server end, it should also be reflected at my application and i should be able to see the the latest/current data coming from the xml file.
            i've tried to do so by many ways but couldn't find the solution. i have found only one solution to this that to reload the page again by timer function for refreshing the application so that it again loads the xml and show me the latest data.
            But for that also is not advisable as it doesn't work if i create a exe of the swf file created as it doesn't reflect the changes for current data.i am embedding the source file. please help me.
            Also i am not sure whether it can be implemented with "Autorefresher" component.
            • 3. Re: Refreshing xml data in flex
              Richard_Abbott Level 3
              I have found with URLRequest and similar calls that to get round problems of the browser helpfully (?) caching the previous results and so giving you incorrect (out-of-date) results, it is good to add a dummy date argument to the end of the URL, something like

              sep_date = new Date();
              my_url = my_url + "?sep=" + sep_date.valueOf();

              You don't then use the extra request param for anything, but the difference in target means the browser does not get in your way. Caching strategy differs between browsers - typically IE seems to hold on for things for longer than Safari say, I think partly because they store the datetime information to different precision.
              Hope that helps,