Page 1 of 1

using stack images in a data grid form

Posted: Tue Apr 12, 2016 3:29 pm
by jim1001
Hello there,

I've been following this lesson
http://lessons.livecode.com/m/datagrid/ ... -of-people

It uses the filename property to specify the image to use when it comes to loading the grid template with data.

I was wondering if it’s possible to use a stack image (e.g. loaded on a resource card) in a datagrid - if it is then how is the image specified?

Any help appreciated.

Thanks,
Jim

Re: using stack images in a data grid form

Posted: Tue Apr 12, 2016 5:16 pm
by Klaus
Hi Jim,

the easiest way is to use simple buttons (disabled etc. to make them non-functional)
and set their ICONs to the id of the desired imported image.

That's the way I do it all the time :D


Best

Klaus

Re: using stack images in a data grid form

Posted: Wed Apr 13, 2016 12:52 pm
by jim1001
Thank you Klaus for this idea. I tried it and it worked nicely.

Now you qualify for a follow-up question about the same lesson :wink:

To what extent does the layout of the template affect the layout of the datagrid? I was hoping that a once the template was created that would define the layout but then slightly dismayed to read further on about a cryptic LayoutControl Message. Can the layout not be seen & adjusted visually before running the app?

Best wishes,
Jim

Re: using stack images in a data grid form

Posted: Wed Apr 13, 2016 12:59 pm
by Klaus
Hi Jim,

I never worked with the "layoutcontrol" message so far, but I think this is only important if you have a "dynamic" layout.
Means it may change its dimensions e.g. after clicking a "disclosure" triangle button to expand your initial layout.

But I may be wrong :D


Best

Klaus

Re: using stack images in a data grid form

Posted: Thu Apr 14, 2016 2:54 pm
by jim1001
Klaus,

Thanks for your reply - and honesty!

Best wishes,
Jim