Saving/importing custom controls to/from file

Monte Goulding monte at sweattechnologies.com
Mon Nov 8 17:12:39 EST 2010


On 09/11/2010, at 7:41 AM, Terry Judd wrote:

> On a whim I tried copying a group and saving the contents of the clipboard
> (clipboardData[“objects”]) to file. I then cleared the clipboard and set the
> clipboardData to the file and was able to paste the ‘reconstructed’ object
> back into my stack. I have to admit that I was surprised that this worked as
> I always just expected that the clipboard data would just contain some
> pointers to the copied objects rather than a usable copy of the control. The
> same also method appears to work for entire cards.
> 
> There may? be some benefits in using this approach compared to saving
> controls in ‘library’ stacks. Is anybody already doing this, and if so what
> are their experiences (pros and cons)?

Hi Terry

I haven't tried but it doesn't seem right to me. Did you quit and restart livecode to make sure memory was cleared.

Cheers

Monte


More information about the Use-livecode mailing list