clars danvold wrote:
> 
> Carl West wrote:
> 
> > An innocuous little script that ran through _all_ the members of _all_
> > the casts and set the fontsize of some them.
> 
> Just curious...
> I have lots of innocuous little scripts that run through all the members
> of all the casts, and do stuff like unlink flash members, or make a list
> of occurrences of a specific member type...
> 
> an example: a handler that searches the casts for members of a certain
> type, whose names contain a certain string:
> 
> on sweepCastsForNameStr aType, aStr
>   tFoundMemList = []
>   tLibCount = the number of castLibs
>   repeat with tCast = 1 to tLibCount
>     tMemCount = the number of members of castLib(tCast)
>     repeat with tMem = 1 to tMemCount
>       if member(tMem, tCast).type = aType then
>         if member(tMem, tCast).name contains aStr then
>           tFoundMemList.add (member(tMem, tCast).name)
>         end if
>       end if
      unloadMember(member(tMem, tCast))  -- <<< *
>     end repeat
>   end repeat
>   return tFoundMemList
> end


* This is essentially what I did to mine and it fixed my problem.
(not pointing it at the 20MB cast that had no textfiles I needed to
adjust the fontsize of helped, improved the load time too)

I found my problem by opening the memory inspector, then I watched for
when the memory got hogged and put a debug breakpoint a little before
that and stepped through until the memory used by castmembers jumped to
40MB. Using these two tools together this way is painfully obvious now
that I've done it. Ah, well, another trick in the bag.


-- 
Carl West    [EMAIL PROTECTED]
617.262.8830 x246    

I have no superfluous leisure; my stay must be
stolen out of other affairs; but I will attend you awhile.

           - Isabella, Measure for Measure, Act 3 Scene 1

[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/lingo-l.cgi  To post messages to the list,
email [EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED])
Lingo-L is for learning and helping with programming Lingo.  Thanks!]

Reply via email to