Sharpharp1
Apprentice

Make a button visible if NO rows are displayed

Hi all,

 

On a editable list view, i have an Add button hidden, but if a user deletes all the rows in the editable list, i want to make the Add button visible, is this possible?

 

Is there a way of saying if "no editable rows visible" set properties of Add button Visible?

0 Kudos
Reply
2 Replies
Vijay_k2
Apprentice

Re: Make a button visible if NO rows are displayed

Hi Sharpharp1,

 

You can try this way.

 

Create a new expression using list count under list aggregators function operators and count your list items using one of your list columns.Then in rules, you can check if expression value is zero then show your add button otherwise hide the control.

 

Thanks,

Vijay

0 Kudos
Reply
Sharpharp1
Apprentice

Re: Make a button visible if NO rows are displayed

Thanks Vijay,

 

I had already tried this, but I looked again after your reply.

 

The problem was this was not working because the record was not saved, if the user hits delete toolbar before it is saved.

So what i've done is hide the Add Toolbar button, forcing the user to hit a SAVE column button, then using your suggestion, the count is incremented and the Add toolbar is showed and the column button hidden with a SAVE method.

 

Shame i can't get K2 to automatically add a new row without the user manually have to click a button. Click button rules do not work if the Row is in edit mode....

 

Thanks

 

0 Kudos
Reply