1

I have a list of a wrapper class which i am using to display values in a pageblockTable.

I want to render this pageblock only when there are records.

I tried using the rendered tag on the pageblock

<apex:pageBlock id="pbmInput" rendered="{!if(wrapperList.size() > 0,true,false)}">

This doesnt allow me to save the VF page

i get the error

Error: Unknown function wrapperList.size. Check spelling

I could have in my controller check the size and accordingly store true or false on a boolean variable and use it.

none of the list function seem to work.. Empty() also doesnt work. Are functions not valid to be used in VF pages?

2
  • What is the body of the wrapperList class? May 17, 2013 at 11:02
  • its a wrapper class holding task,contacts and leads.. The issue is not with the wrapper class
    – Prady
    May 17, 2013 at 12:00

1 Answer 1

5

Take the () off the end of size so it reads

wrapperList.size not wrapperList.size()

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .