One Use Only Files

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: Klaus, FourthWorld, heatherlaine, kevinmiller

Posts: 495
Joined: Wed Feb 21, 2007 7:58 am
Location: Australia

Re: One Use Only Files

Post by bidgeeman » Tue Aug 22, 2017 7:32 am

I have a new problem and not sure what's causing it. When I load a set of thumbnails from my online folder
sometimes they come in first go and sometimes I have to press the load button twice to get them to load.
Same happens when I use "put empty into image'1". Sometimes all the images empty sometimes a few
at the bottom remain? I tried it with a standalone and same thing happens?

Any suggestions?

Posts: 1576
Joined: Tue May 28, 2013 2:20 pm
Location: Italy

Re: One Use Only Files

Post by MaxV » Tue Aug 22, 2017 12:59 pm

bidgeeman wrote:MaxV wrote:
The (livecode) software load the image at low resolutions (adding your logo, etc.), user can modify it. Then he pays you, and you give the ok to print at full resolution, without logo, etc.
I*s there a way to control the resolution of an image or are you referring to loading a low res/snapshot copy of an image?
Not come across resolution controls in LC yet but it sounds very interesting. I have noticed that when you resize and image then export a snapshot, the image maintains the resolution of the resized version. Maybe that's what you were referring to? Resize then export snapshot? Aside from that,
dealing with a database is a bit out of my league at the moment unfortunately :(

To learn to use a database just read this: , you don't need any other software.
The resolution of an image is contained in the imageData property, but it is a little complicated.
If you set the imageData, you specify the bits of the images, so the rect property must be correct; otherwise image became a mess.
Now you can resize the image, livecode will adjust what is on screen, but the imagedata remains of the full resolution. Then you can set the imagedata of the image to the imagedata of the image :lol: : this is the tricky part, because when livecode look for the imagedata, it captures the image data on the screen and store into the image, so now the image is a low resolution.
So to lower the resolution, you should:
  1. set the correct rect of the image myImage
  2. set the imagedata of image myImage from the original image
  3. change the rect property to a smaller size (or just width or heigth)
  4. set the imageData of image myImage to the imageData of image myImage. Now If you try to enlarge the image, the image became pixelled, because the resolution is now low.
Livecode Wiki:
My blog:
To post code use this:

Posts: 495
Joined: Wed Feb 21, 2007 7:58 am
Location: Australia

Re: One Use Only Files

Post by bidgeeman » Tue Aug 22, 2017 1:03 pm

Hi MaxV
That info on resolution is fantastic to know. Thank you for sharing. I have also bookmarked the
wiki and will look into it tomorrow.

EDIT: Just to add to the resolution I did notice if you manually resize an image in LC then right click
the image opens in your editor at the resolution you resized it to.

Thanks again

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”