On 23/03/2012 06:48, Terry Judd wrote:
Hi Ken - don't know if it will help but what I usually do is put group the form
datagrid inside of another group (with the datagrid as the only member) and
then lock the 'parent' group to the required size. Then, each time I update the
datagrid I set it's height to the maximum value of the height of the parent
group and the dgFormattedHeight of the datagrid. I use this same value to set
the scroller object's dimensions.
Yes, it all helps!
The solution, for me, was to:
1) add this to my card where the group was:
on scrollerDidScroll OffsetX, OffsetY
set "dgScrollbarDragV "&OffsetY to group "<group of datagrid>"
set "dgScrollbarDragH "&OffsetX to group "<group of datagrid>"
end scrollerDidScroll
2) ensure that the rect and contentRect properties start correctly:
iphoneControlSet sScrollerId, "contentRect", (0,0,320,2500)
iphoneControlSet sScrollerId, "rect","0,0,320,460"
3) Use your maximum tip to set the height of both the datagrid and the
contentRect of the scroller.
4) I don't know what the effect was, but the datagrid's position was
unlocked. I locked it.
I was ready to decide it just couldn't be done in LiveCode when it was
just a few lines away.
Now on to figure out how to do it on Android.
-Ken
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode