14

Using a Wait (now called Pause) element does preserve the Flow's state, including all of its variables and the field values of queried sObjects, across the boundary into a new transaction. As expected, limits are reset across the transaction boundary. This strategy is more or less explicitly endorsed by the documentation: A transaction ends as soon as a ...


6

According to the documentation on Getting Flow Variables, you should call myFlow.getVariableValue: String accountId = (String)myFlow.getVariableValue('accountId');


5

As per the documentation: https://developer.salesforce.com/docs/component-library/documentation/lwc/lwc.get_started_supported_experiences LWC is not supported in Visual flows as of now! As mentioned, you can wrap a lightning web component in an aura component, and can use the same in flows, and in many other experiences and tools where LWC is not supported!...


5

This is the bug: https://success.salesforce.com/issues_view?id=a1p3A0000003UVoQAM horrible stuff and I hope they put effort into getting this fixed. The only way to edit the flows currently is to hand edit the XML in the package. edit: or on a scratch org. They can be opened there. Flows & Processes are currently inaccessible through the UI on both ...


5

Apex is superior in all three categories for maintainability, scalability, and efficiency. Flows typically take longer to edit than code, do not run efficiently, and may cause problems on bulk updates. If you're given a choice, prefer using Apex when possible. Flows are really only meant for simple logic.


4

FlowTestCoverage is part of Tooling API. If running from Query Editor in Developer Console, you need to enable Use Tooling API option in the Query Editor in Developer Console (option available besides Execute button, screenshot below).


4

A SOQL query is any query to Salesforce where you're trying to lookup a record. Think of it kind of like when you do a search in the Salesforce search bar for a record. That is 1 query. (Although technically that's a SOSL query... but that's not relevant). When you build a Flow, anytime to do a "Record Lookup" or "Fast Lookup", that'd be 1 query. In ...


4

The FlowTestCoverage object is only supported in the Tooling API, so if you're running the query from the developer console, you should check the 'Use Tooling API" box next to the "Execute" button before you run the query.


4

You can use recordId variable in flow to get the record id of Case. If it is coming as null, then you can assume that it is homepage otherwise it is executed from Case record page. Refer 2nd answer in the given thread to understand how to pass recordId to flow from a record page: How to pass parameter to flow launched from Quick Action You just need to do a ...


4

Change public Flow.Interview interview { get; private set; } to public Flow.Interview.My_Flow_Unique_Name interview { get; private set; } The VF page saves after compilation in developer console.


4

It's definitely a bug in the new flow designer. It's not because of Sum19 release. I also faced a similar issue recently in Spring 19 scratch org and when switched back to legacy flow builder, I was able to add invocable action in flow. This link also reports the same issue. https://success.salesforce.com/answers?id=9063A000000E47kQAC I wasn't able to find a ...


4

The CPU time limit is a cumulative limit across the whole transaction. Essentially, what is happening is that your Flow, plus your Process invocations, plus the NPSP triggers that are run consequent upon the updates you are making, are taking too long to execute in a single transaction (10 seconds of CPU time). Because the CPU time limit is a cumulative ...


4

Please note that you get the same error code if you have Apex validations. For example, if your trigger calls: MyObject__c.MyField__c.addError('message'); Any validation thrown using the above methodology will also yield: FIELD_CUSTOM_VALIDATION_EXCEPTION


3

The parameters in Store Output Values are usually used when you have input fields in a Lightning component that you want to use elsewhere in your flow. For example, in the Phone screen component, you would need to set a resource variable in the Value field under Store Output Values if you wanted to use the value that the user input in that field. The ...


3

You can actually do it with a Process, or with a Flow, or with an Apex trigger. The Process is simplest. To build a Process to do this, start from Contract. Establish your action criteria nodes, then add an Immediate Action. Select Update Records, then navigate through the Account node to "Contacts" (under the Account). Select that entry. Configure your ...


3

To make the components available in flow screens, edit the lightning web component configuration file to include a target of lightning_FlowScreen. For example: <?xml version="1.0" encoding="UTF-8"?> <LightningComponentBundle xmlns="http://soap.sforce.com/2006/04/metadata"> <apiVersion>45.0</apiVersion> <isExposed>true</...


3

The InvocableMethod interface is bulkified. This allows you to map flows within Process Builder in a bulkified manner. As the documentation states, your parameter must be... A list of a primitive data type or a list of lists of a primitive data type – the generic Object type is not supported. This means that to pass in a collection, you actually need to ...


3

Thanks so much, @rodrigo -- I still needed additional help in another forum before I could make use of your answer; I'd like to "explain it like I'm five" and add some additional details for others who come to this post as confused as me and can't quite get going with that answer alone. Here are a few important things to know about Invocable Apex and Apex-...


3

When a flow starts, that version will be used throughout the entire flow process. This means that users using the flow before you make the new version active will continue to use the old version for the rest of the flow process. Flows started after the new version is activated will use the new version.


3

You do not need a validation rule or a field. You can build this logic in the Flow directly. That design will look like the following: Obviously, you'll need to tweak this a bit to suit your purposes, but it should be straightforward once you have the proper layout.


3

Records are updated at the moment you hit an update element. In other words, yes, you must bulkify your flows just as you would in Apex or the API. Place DML operations outside of a loop, or you'll run into limits quickly.


3

You'll want to chain together the decisions so that you can check all four conditions. That part will look like this:


3

am i missing something obvious? If I understand the problem correctly, yes. It should just be as simple as checking if the update is meaningful before actually triggering the update. I'm not going to "draw" this out in the builder, but the flow should simply be: Fast Lookup existing user record (Fast Lookup). Check if title on user record matches incoming ...


3

No. As of today its not available. You can keep checking the documentation Base Components: Aura Vs Lightning Web Components to know: The table lists usage differences between Aura base components and their Lightning web component counterparts.


3

You are right. OR conditions don't work for multiple field. A workaround would be to use to 2 Get Record elements. One for UserId another for Email. After each Get Record use a Loop element to iterate over fetched records and add in a Record Collection Variable. Flow would look something like this: Record Collection Variable may contain duplicates which can ...


3

that's not possible for the moment if you can use only the standard components. there are 2 possible ways: Custom Lightning Component Packages from AppExchange (i'm not sure if there's a package for that, but you can give it a try) You can upvote an idea that asks the same thing that you questioned. I'm sorry for my english, i hope you understand what i ...


3

The versioned FlowDefinition object is no longer recommended as of API 44.0, in favor of the unversioned Flow, which is the point at which behavior around Flow versions changed in the Metadata API. Using API version 43.0 or prior to retrieve FlowDefinition should return the original versioned files.


2

I had the same issue, my message looked a bit different, but you can easily adjust the formula below. Creating the Formula You have to create a formula variable in your flow and enter the formula below MID( {!$Flow.FaultMessage}, FIND('FIELD_CUSTOM_VALIDATION_EXCEPTION: ', {!$Flow.FaultMessage} )+34, ( LEN({!$Flow.FaultMessage} ) - (FIND('...


2

The above solution gets all the more simplified with Salesforce's latest release. Now looping through a collection of records, incrementing the counters is no longer needed. Instead the record count can be easily fetched in a sobject collection variable and assigned to a number variable. No more need to loop around to fetch the count. Get it directly in a ...


2

I preach the gospel of Declarative Lookup Rollup Summaries a lot, but it's because it's such a good tool for requirements like this and so many admins don't know about it. Free, open source project, fully declarative, can roll up almost anything to almost anything, etc. Specifically, here, you'd want to have a DLRS "Concatenate Distinct" rollup from Contact ...


Only top voted, non community-wiki answers of a minimum length are eligible