So Summer 20 Release is round the corner and the most highlighted feature of this release is “Dynamic Forms and Action“.
Dynamic form are an addition to Lightning Record Pages which gives more power to admin to control the Visibility on Record pages without touching the existing classic page layout.
For me its kind of DIY feature in Salesforce. With this admins get more flexibility to maintain pages without having to care much of Profile level changes. This is one #LowCodeLove feature which will give much flexibility to Admin.
Dynamic Forms is a Non-GA Preview and has limitations. However, you can use this in your pre-release org.
This is currently available for the Custom Object.
Business Use Case :
There is a requirement for the Student Record Page which has a different section like Student-Information, Parent Information, Other Information.
We have additional Requirements that Emergency Contact Number (Field) will be shown only if there is data and Marks (Fields) of Student will be shown only if mark is more than 0 in the database for the record.
We need to show a section “Parent Information” to System admin Profile only.
Solution :
- Create an object Student
- Create Fields as required. In my case, I have created as shown in the below screenshot.
- Now create a Tab so that we can create Records for this Object.
- Now we will create a Lightning Record Page from 4th option present in left side of the above pic.
- Click on New and Select Record Page. Give Label and Object and click on Next.


Select a Template and click on Next. I have chosen the First one only. This is how default one looks like.

Now we will start our actual Solution .
Firstly we will enable this Setting of Dynamic form in our Org. Go to Set up under User Interface , You will find Record page Settings

Click on the Record page Setting and Turn it ON for your Org. Do give a read for all the Agreement Notes , before turning it on. I have already turned it on so it is showing ON in the screenshot.

Once this is done we will move back to our Lightning Record page that we created .
And Will Drop Record Detail to our Record page and once it is dropped You will be able to see upgrade now section in the Right hand side .

Click on upgrade now and a pop up appears for Dynamic Form click on Next and select the Record page that appears and Click on Finish and WOAHHH your Record page is Converted to Dynamic Forms now.



If you see the sections highlighted
- Rights side top which shows the fields of this object
- Centre shows the Form
- Left hand side shows the section .
Now i have configured the page by adding section and dropping the fields.

Now the First part of Requirement is Complete that we need to make a form with Student Information ,Parent Details , Other Details
Now Let’s make changes to Emergency Contact Field and Marks and control its visibility.
Click on the Emergency Contact Details Field and Check if this is not equal to null in the way shown in Screenshot.

Click on the Marks Field and Check if this is not equal to Zero in the way shown in Screenshot.

Coming to last requirement that this Parent Details section will be visible to Admin only.
Click on the top of Parent Details Section go to Set component visibility and click on advanced and Choose user and its Profile name field and after choosing the Field give its value as System Administrator.

So our Configuration is complete . We will click on Save and Activate the record page and we are Ready to Test the Output .

Parent section is visible here as i am logged in with System Admin Profile . In Below profile I am logged in with Test User having Profile other than System Admin and you can see there is no Parent Details Section

This is how we were able to solve the whole business use case.
You can even try and explore it more. Please Try this in your Pre Release orgs and let me know the feedbacks.Thanks !!! Stay Safe Stay Home
Courtesy:
Salesforce Documents, Dynamic Form images and Vin Addala’s Tweet.