function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
AmyJonesAmyJones 

Unable to hide section

I am using below but the text is still showing

rendered="{!objTenant.Applicant_Status__c=='Submitted'}"
ANUTEJANUTEJ (Salesforce Developers) 
Hi Amy,

Could you elaborate the use case with code additionally can you try checking the below link as it has a similar implementation of expanding and collapsing the page block that you could use:

>> https://www.forcetree.com/2010/04/expand-collapse-pageblock-table-columns.html

looking forward for your response.

Regards,
Anutej
Shaan Khokhar 9Shaan Khokhar 9
Hi Amy,

You could something like this inside your extension class, i have used this method before.

So you could have something like rendered="{!isApplicantSubmitted}" with the function:
list = New List<object_name>(); 

 public Boolean isApplicantSubmitted {
        get { 
            for (object_name obj : list) {
                if (obj.Applicant_Status__c == 'Submitted'l) {
                    return true;
                }
            }
            return false;
        }
      }





 
AmyJonesAmyJones
I have tried adding the below and getting Error: Compile Error: Missing '<EOF>' at 'List' 

List = New List<tenant__c>(); 

 public Boolean isApplicantSubmitted {
        get { 
            for (tenant__c obj : list) {
                if (tenant__c.Applicant_Status__c == 'Submitted'l) {
                    return true;
                }
            }
            return false;
        }
      }
Shaan Khokhar 9Shaan Khokhar 9
That's because the boolean is a class, try this instead:
 
public List<tenant__c> list{
        get;
        set;
    }



 
Israel JimenezIsrael Jimenez
Hi AmyJones, 

I had the same problem and... maybe you can try with this...
rendered="{! IF(objTenant.Applicant_Status__c=='Submitted', true,false) }
Works me!

Regards!