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
SFDC n12SFDC n12 

Field visiblity help

Hi,

I have 4 number fields which shouold be visible or to be edited only if


The value of a picklist field "Type__c" is set to "Exception" , apart from that those number fields should not be visible or non editbale


Let me know how to achieve this

Thanks in Advance
KaranrajKaranraj
Are you trying in Standard page layout or in Visualforce page? If it is standard page then it is not possible, In visualforce you can able to do that using rerender attribute.
ShashForceShashForce
This can be achieved by updating the record type using a workflow rule, and assigning a different page layout for the new record type which does not have this field on it. This is only when you have record types feature available in your org.

1.) Create a workflow rule with criteria Type__c = "Exception", and add a field update action which changes the record type of the record to a new record type.
2.) The new record type should have a new page layout assigned to it, which has this field as visible and editable on the layout.
Sagarika RoutSagarika Rout
This requirement  can be achieved using standard functionality and customization as well.
Using Standard functionality , crate one record type , add those number fields to the page layout of the respective record type.then on picklist change assigh the record type.
Using visualforce page , onchage of picklist field value  to "Exception" ,set  one boolean variable to "true", and on renderd attribute of those fields just assign boolean value.

Regards
Sagarika