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
DCBoyDCBoy 

View different page layouts

I have two page layouts (standard detail pages, not Visualforce) for Case. The user by default gets the first page layout when he clicks on a case number. The first page layout has very few fields (max 10). A button on the detail page should take him to the second page layout where there many more fields from the Case object (~50). Is there any way this can be achieved using minimal coding? Here are the options I have already explored

- Changing record type on th case record on click of the button [Unnecessary update on the record]

- Tried changing profile of the logged in user [Apex exception - cannot change logged in user's profile id]

- Creating one of the page layouts as a visual force page [Code maintenance cost is high]

 

Are there any other ideas with minimal coding that can be explored?

Best Answer chosen by Admin (Salesforce Developers) 
DevGarethmdDevGarethmd

Seeing as you're looking to keep things simple I would suggest just using one page layout and using collapsible sections in your page to group fields together and allow your users to control whether they see those fields by collapsing or expanding the section. You could for example, have one section where you put the fields you want to display all the time and a second section to contain the 50+ fields that should be displayed when the user needs to see them.