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
PkPk 

I'm asking for help in doing this task and send it here or to my email and I'll understand what needs to be done, thank you in advance

1. Create a new field on Case: Name: Owners Manager Email Type:    Email  

2. Create a Flow (autolaunched) and a Process Builder:  Flow Name: Case Owner Manager Email Flow Description: This flow is used to update Owners Manager Email field when Case is created or when the case owner is changed. Logic:

1. Check if the case owner is a User or a Queue.

2. If the owner is a Queue, or a User that has no manager, do nothing.

3. Else (the owner is a user with a manager), populate the field "Owners Manager Email" with the email of the owners Manager.  

PB Name: Case PB Criteria: When Case is created or the case Owner is changed. Action: Launch Flow.

3. Create a Screen Flow & Action: Flow Name: Create Contact Flow Description: Screen flow to make it easier to create a contact.

Logic:

1. Show a screen with those contact fields:  First name, Last name, Mobile and Email.

2. Check if a contact with the same mobile OR email already exist in the system.

3. If such contact already exists, show a screen "Contact already exist for Account xxxx" where xxxx is the Account name of that contact.

4. If the  contact does not exist, create new contact under the current
Account.
Sai PraveenSai Praveen (Salesforce Developers) 
Hi Patrick,

As mentioned in my answer on below question I am answering third requirement here.

https://developer.salesforce.com/forums?id=9062I000000UiV4


For this requirement we need to create a screen flow as below.

1) Create a new resource  variable with name as recordId this is case sensitive and it should be same and type as text as below .
User-added image2) As we want the screen for users to populate four  components so put a screen component and drag and drop two text components for (Firstname and LastName) one mobile field and one Email field and make them required as shown below give the API names for all the fields.

User-added image
FirstName and Last name will be similar to below

User-added image
Email  and Mobile will be similar to this:
User-added image

Now get record element and get contact information with that email or mobile as below.

User-added image

I will continue the remianing screenshots in my next answer as we can upload till 5 screenshots for an answer.
 
Sai PraveenSai Praveen (Salesforce Developers) 
Cont....

Now put a decision box to check if contact exists or not.

User-added image
In the yes side add a screen to show the message and drag display text and write the text as below.

User-added imageIf contact does not exists cretate the contact on other side of the decision box:

User-added image
The entire flow looks as below.

User-added image
Save the flow ans activate it.

I will continue adding the action button in next answer.
Sai PraveenSai Praveen (Salesforce Developers) 
Cont...
Now go to object manager-> Account->Button Links and Action-> and Click on new Action button and fill the details as below.

User-added image

Add the action to the page layout and test it.

I have tested it and it is working as expected.

Let me know if you face any issues.

If this solution helps, Please mark it as best answer.

Thanks,
PkPk
Hey ,

Thank you very much indeed.
I can't do this step: how to start with it:?
1) Create a new resource variable with name as recordId this is case sensitive and it should be the same and type as text as below....
Sai PraveenSai Praveen (Salesforce Developers) 
Hi Patrick,

On the left side of the flow builder you will see Create resource button just onclick it and give the varible name and remaining as below.

As mentioned above variable name should be recordId ans it is case sensitive.

User-added image

Let me know if you face any issues.

If this solution helps, Please mark it as best answer.

Thanks,
PkPk

Hello,
thank you very much, you explain very well and I am still in the stages of preparing the flow, I would like to understand why a variable should be added? 

 

In addition, I have a question that I am asked to understand (I would be happy to get an explanation from you if you have any idea) the question:
 
 In the field there is the following formula which checks the values ​​in the picklist and text fields and returns 1 or 0 respectively:
 
 if((Picklist__c="Call Later" && CB__C=False),1,0)


And if you can also explain what is the meaning of this formula or holding (from what you can understand from it)?

Thanks in advance,

and many blessings,

 

Sai PraveenSai Praveen (Salesforce Developers) 
Hi Patrick,

We need variable in this scenerio because when we create new Contact we have to relate that contact to the Account on which the button is onclicked which means we need the Accountid. So we are using the variable to get it.

Regarding the formula:

I hope the formula return type is checkbox. This checkbox checks to true if Picklist__c value is "Call Later" and CB__C = False . If it does not satisfies both the condition then checkbox will be false I guess.

Let me know if you need any help.

Thanks,

 
PkPk
First of all I want to thank you very much and thank you very much
Flow works perfectly and correctly
bless you

Regarding the formula assuming that this is what it does, then the question is asked what is wrong with the syntax of this formula?

(They present the formula incorrectly so we can correct it)

Assuming this is what you explained in the previous answer, how do you correct the formula to write it correctly?

Right now she is like this:?

 if((Picklist__c="Call Later" && CB__C=False),1,0)

What fix would you suggest?
Sai PraveenSai Praveen (Salesforce Developers) 
Hi Patrick,

For picklist we have to user ISPICKVAL() or TEXT() function.

The formula would be as below
 
if((Text(Picklist__c)="Call Later" && CB__C=False),1,0)

Let me know if you need any help.

Thanks,

 
PkPk
Thank you very much, just now everything is working out for me
You are a genius, you teach excellently and help to understand what is being missed.

If possible another small and last help for now

How do I make Flow for the following question: ?

When Contact's object records are updated, "Number of Updates" field will be updated as follows:
The field should count the number of clicks on the "save" button in a specific contact record. Meaning, in every update, 1 will be added to the field's last value (every update: +1), For example:
Number of Updates = 5
After saving the Contact's record, "Number of Updates" field value becomes 6
and so on.
Sai PraveenSai Praveen (Salesforce Developers) 
Hi Patrick,

Thanks for ansking another questions but can you post it as other question so I can pick it fresh question just to make Community question helpful for others. 

Thanks,

 
PkPk

Yes

Here:

https://developer.salesforce.com/forums/ForumsMain?id=9062I000000UiXo#!/feedtype=SINGLE_QUESTION_DETAIL&dc=Trailhead&criteria=OPENQUESTIONS&id=9062I000000UiiSQAS

Thank you very much

 

PkPk


Hi Sai,

 

The second part of the FLOW i.e. creating a new contact does not work and it brings the following error (as in the screenshot):

Fileds

Eror Flow

Any idea how and where to fix it?

Thanks in advance,