Hi Dragan,
Thanks for your reply. Got the idea. We just need to populate it not only vertically but horizontally as well.
If these were instantiated into a container control, can a container "grow scrollbars"? Or should we just add commandbuttons for "navigation"?
Dennis
>>Hi All,
>>
>>Anybody ever did a class that creates command buttons to represent records in a table? Am planning to use this type of UI to show the students in a particular section -- or maybe there is a much better idea, I will be happier for that.
>
>That should be easy - simply
>
>
lnTop=0
>scan
> lcName="btn"+transform(recno())
> this.addobject(lcName, "commandbutton")
> loButton=this.getpem(lcName)
> with loButton
> .top=lntop
> .caption="Button # "+transform(recno())
> lnTop=lnTop+.height+2
> .visible=.t.
> endwith
>endscan
>
>Of course you may want to set more properties, and of course you will run out of vertical space. You may want to introduce multiple columns of buttons, if you like.