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
SV MSV M 

 Create a check box on opportunity if stage value is closed won  checkbox should be true else checkbox should be false

 Create a checkbox on the opportunity if stage value is closed won checkbox should be true else checkbox should be false. Help me create a validation rule for the same.
Andrew GAndrew G
Hi Sai

Not sure why you chasing the checkbox, but are you aware that there are already 2 x checkboxs by default, one called IsClosed and the other IsWon

Would those standard fields help remove your need for an extra checkbox?


Regards
Andrew
 
SV MSV M
@Andrew G
Please let me know where I can find those checkboxes and how to use it since I'm new to Salesforce
Andrew GAndrew G
Hi Sai
They are not visible in design of the Opportunity object and therefore cannot be added to the page layout.

They are able to be queried when using SOQL or if you view the design via the Developer Console.
User-added image

The fields can also be used in Filters for Reports on the Opportunity record. 
Or they can be added to list views, using the field names Won or Closed.
They are populated by standard processes in Salesforce.  And will be marked checked based on the Stage Name Type when the Stage is updated in the Oppty.  
User-added image
In the above image, both boxes would be checked when the Stage becomes either Closed Won or Target.  If the Stage becomes Closed Lost, only the IsClosed box will be checked.

Hope that is helpful

Regards
Andrew
 
SV MSV M
@Andrew G
Thanks for your response...
SV MSV M
Hi, Can we validate text data type to format the phone number same as the Phone data type? If possible, please let me know how?
ots khanots khan
You can take the help from here (https://otsresults.org/)