TIP: isImagLoaded function

Ken Ray kray at sonsothunder.com
Thu Jun 23 14:00:55 EDT 2005


On 6/22/05 1:50 AM, "MisterX" <b.xavier at internet.lu> wrote:

> Hi all!
> 
> Here's a couple new TAOO XOSMediaLib functions im sure many are going to
> enjoy!
> 
> However I know this one feature is much needed so i can release it outside
> the TAOO framework.
> 
> here's the little add-on-script i made to see if an image existed or was
> loaded and by what stack.
> 
> To use it, just script
> 
> get imageNameexists(987654)
> get imageidexists(987654)
> 
>  -- it will return which stack or false.

The problem is that this doesn't handle images anywhere other than the
"current" card of a stack, and they have to be raw images sitting on the
card (i.e. not in substacks or groups, etc.).

So you should expand your code Xavier to support *any* images in a stack,
otherwise the purpose of the code (to find if there is an image loaded of a
particular ID) is defeated. You have a good framework to get this working -
you just need to expand on it.

Ken Ray
Sons of Thunder Software
Web site: http://www.sonsothunder.com/
Email: kray at sonsothunder.com



More information about the use-livecode mailing list