View Full Version : resizeable grid
epopov
04-15-2004, 08:20 AM
Hi,
how to make resizeable and sortable grid based on basegridcolumn controls?
Can you give me some example?
At least in the version of the reference on our website doesn't have an entry in the index for this page:
http://laszlosystems.com/lps/docs/lzx-reference/basegrid.html
but it has a little basegridcolumn example code. If you still have questions after looking at that, post 'em here.
mdavis
04-15-2004, 11:50 AM
basegrid columns behave, in many ways, like regular views. I've written a very simple case below that controls the width of the column from an input box and button, but it could also very easily be constrained to a resizable view elsewhere on the canvas.
Let me know if this doesn't get you unstuck.
<canvas>
<dataset name="contacts" request="true"
src="http://laszlosystems.com/lps/sample-apps/contacts/contactsdata.xml"/>
<simplelayout/>
<edittext name="wide" text="200"/>
<button text="Set Width" onclick="canvas.grid.setAttribute('width', canvas.wide.text)"/>
<basegrid name="grid" datapath="contacts:/resultset" width="200">
<basegridcolumn>
<text placement="header">Check 'em off</text>
<checkbox text="$path{ '@displayname'}"
value="$path{'@checked'}">
<method event="onvalue">
this.datapath.updateData();
</method>
</checkbox>
</basegridcolumn>
<scrollbar placement="content"/>
</basegrid>
</canvas>
vBulletin® v3.8.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.