I have a basic chart that shows dashboard information, so I have it calling the service every 30 seconds. Here’s the code:

private function initApp() {

            srv.send();

            timer = new Timer(30000);

    timer.addEventListener("timer", callService);

    timer.start();

 }

 

public function callService(e:Event) {

            currentRefresh = new Date();

            currentRefresh = dateAdd("h",currentRefresh,-1);

            srv.send();

}

If I take this out, it runs fine…if I add this, after time it gets insanely slower – give it 3-4 hours and it’ll take 95% of your CPU usage. Is there something wrong with timers in Flex2? All the service does is call an xml file which the results are bound to a chart.

_________________________________________

Jonathan Miranda

Flexible Master of the Web

"In the game of chess, it's important to never let your opponent see your pieces."

HealthGrades: Guiding America to Better Healthcare™

NASDAQ: HGRD

w  (720) 963-3832

c  (707) 761-0868

[EMAIL PROTECTED]

_________________________________________

The message contains confidential and/or legally privileged information and is intended for use only by the indicated addressee.  If you are not the named addressee you should not disseminate, distribute, or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmissions cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed,arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version.

 



--
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




Reply via email to