Filename of an image

Peter Haworth pete at lcsql.com
Sun Feb 15 02:29:28 CET 2015


Thanks Rich.  I've temporarily been working round the issue by deleting the
image and creating a new one as you mentioned. Fortunately, there's only
one image with the filename in question.

I was hoping there'd be a more elegant solution than deleting and creating
a new image but maybe that's the way it is.  I guess I could create my
image file with a different name every time I create it.

Sounds like there should be a way to switch off image caching.

On Sat Feb 14 2015 at 5:04:56 PM maring.richard <maring.richard at gmail.com>
wrote:

> Peter,
>
> It is indeed the cache. I spent an entire day trying to figure this one
> out.  I finally found that if there is any reference to that filename in
> any image container anywhere in your code the cache will not release it.
>
> Also changing the image file and reloading it will not clear it from cache
> either as the file was never deleted.
>
> What worked for me was to delete the original image file. The I put the
> word "junk" into the filename of every occurrence of that image container.
> Did a wait of 5 milliseconds then loaded any modified copy of the original
> and it worked.
>
> I had a scratch stack that I occasionally placed substances in for various
> reasons. I found that one of them had an image container that had my image
> filename in it and it was the reason the cache wasn't releasing the file.
> Had forgotten it was even there. It is never called or opened but the cache
> new it was there.
>
> Hope this helps point you in a direction that helps.
>
> Rich Maring
>
>
>
>
> Sent via the Samsung Galaxy Note® 4, an AT&T 4G LTE smartphone
>
>
> -------- Original message --------
> From: Peter Haworth <pete at lcsql.com>
> Date: 02/14/2015  6:32 PM  (GMT-06:00)
> To: How to use LiveCode <use-livecode at lists.runrev.com>
> Subject: Filename of an image
>
> If I set the filename of an image, it correctly loads that file into the
> image.
>
> Say I then change the contents of the file - if I set the filename of the
> image again, the original file contents remain in the image, presumably
> because of some caching effect.
>
> Is there a way to force the image to be reloaded from the file?  I tried
> setting the filename to empty but that gave me an error (in the message
> box).
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


More information about the use-livecode mailing list