0

dynamically hide a column for a grid

asked 2007-10-04 12:48:56 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=4551958

By: saibal4477

Hi

I am a newbie on ZK.
How can I hide one column (along with all rows) from a grid from the onclick event handler for a button ?

regards
Saibal


delete flag offensive retag edit

4 Replies

Sort by ยป oldest newest

answered 2007-10-05 01:33:21 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=4553244

By: jebberwocky

Dear Saibal

In my knowledge, there is no straight-forward method to call to accomplish it.
As a work-around, y-Grid is good choice. Please refer the smalltalks about this topic. There are plenty of them in http://www.zkoss.org/smalltalks/.



link publish delete flag offensive edit

answered 2007-10-05 03:42:25 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=4553358

By: henrichen

try

int col = 1; //0-based, hide 2nd column of the grid int rowsize = grid.getRows().getChildren().size();
for(int row=0; row < rowsize; ++row) {
grid.getCell(row, col).setVisible(false); }

/henri

link publish delete flag offensive edit

answered 2007-10-05 11:15:53 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=4553831

By: saibal4477

Thanks to both of you Henri and jebberwocky, I decided to go with y-Grid which suites my pirpose. BTW I am a new developer to ZK and getting surprised with its power and ease of use. Thanks to ZK team...

link publish delete flag offensive edit

answered 2011-05-28 04:00:34 +0800

samit1010 gravatar image samit1010
15

how to get Column Dynamically from Database please show me with code..................................

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2007-10-04 12:48:56 +0800

Seen: 447 times

Last updated: May 28 '11

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More