Good day!
I am using default UI of Salesforce, so no customization or anything. Everything is default, I want to achieve the solution of my problem by using default UI.
So, I actually want to hide a field while creating a record but show the field in the record detail page. How can I achieve it? By not using any custom component!
I tried:
Modifying the page layout, but it modifies for both record detail page and new pop up page. I can not modify them separately.
Thanks a lot in advance!
1 Answer
You can achieve this by creating record types for the object. One record type for creation with its associated page layout which doesn't have the field and another record type with associated page layout which has the field.
You will also need a workflow rule which fires only when a record is created to flip the record type of the record.
So when a user creates the record he/she will not see the field but when the record is saved the field will appear because of record type flip done by the workflow rule. However, use this solution only its absolutely required as there is a maintenance cost due to 2 record types and 2 page layouts.
Another method would be to customize the creation page via custom component, but then you will have to write code to create the UI and do an insert call to save the record using standard or custom codes.
-
Thanks for you reply. Yes, creating 2 record types, 2 pages bit costly. So, is there any way to add the field dynamically to the record detail page by using workflow?– MehediCommented Oct 12, 2020 at 4:25
-
-
1No There is no other way apart from the two I mentioned. Workflow rule is for updating records not add metadata. I consider development of custom component as optimal way. Commented Oct 12, 2020 at 13:31