2 Replies Latest reply on Jul 5, 2007 4:36 PM by avonova

    flush()-ing shared objects

      I'm currently trying to get my head around using SharedObjects in AS2 and was wondering if anyone else has also had this happen and whether a remedy exists - here's the issue:-

      while using mySO.flush() with some simple code, as a trial to save some test data to a client harddrive, i've found that the flush() method saves the required data only on the second click of the relevant button.

      here's the code for the button (the button is just a coloured circle):-
      button1_btn.onRelease = function(){
      . . .

      i'm running XPproSP2 on a dual x64 and was wondering whether the dual cpu was an issue?

      thank you for any suggestions.
        • 1. Re: flush()-ing shared objects
          Rothrock Level 5
          I take it that you've done the getLocal and created the SharedObject. I haven't done a whole lot with SO, but I've never run into this problem. How do you know that it isn't flushing?
          • 2. Re: flush()-ing shared objects
            avonova Level 1
            yo Rothrock,

            the shared object is created and getLocal is used.

            i'm using sol editor by alexis issac to read the 'external shared object file' - kinda like some visual feedback while i'm making changes within the simple flash app. when i click the flush() button in flash i can monitor the external file with sol editor.

            N-O-W, as a result of replying to your post Rothrock i've found the 'wrinkle' in my code; i didn't have the flush() command in the appropriate place within my code (coder error).

            now that i've editted my code it's flushing the data to the external file at the first click, just as i require.

            many thanks for your contribution, it got me where i need to be, i appreciate that.

            best wishes,