You need to sign in to do that
Don't have an account?

Automate Post-Workshop Tasks with Invocable Apex
I am in the last action where the process builder calls the invocable apex class. When i look for the class it appears with the LabelName
'Give a Thanks Badge' and the lookups do not show up on the Giver Id and Receiver Id fields. Can someone tell me what am I doing wrong?

If i put the apex class name as is shown in the trail it still does not find the Giver Id and Receiver Id values. My apex code has an active status.

Thank you.
'Give a Thanks Badge' and the lookups do not show up on the Giver Id and Receiver Id fields. Can someone tell me what am I doing wrong?
If i put the apex class name as is shown in the trail it still does not find the Giver Id and Receiver Id values. My apex code has an active status.
Thank you.
All Answers
Thanks!
Invalidtype WorkThanks
Challenge Not yet complete... here's what's wrong:
There was an unexpected error in your org which is preventing this assessment check from completing: System.DmlException: Update failed. First exception on row 0 with id 7017F000000QMEQQA4; first error: CANNOT_EXECUTE_FLOW_TRIGGER, The record couldn’t be saved because it failed to trigger a flow. A flow trigger failed to execute the flow with version ID 3017F000000IWAK. Flow error messages: An unhandled fault has occurred in this flow
An unhandled fault has occurred while processing the flow. Please contact your system administrator for more information. Contact your administrator for help.: []
I am in the last section of this module, written the Apex class with Invocable Method and Variables without any errors. But when I change the Campaign details of Type to Dev Class and Status equals to Completed, I am getting the below error message. Please help me to complete this module.
Regards
Sreenivvas Venkatesh
Error Occurred: An Apex error occurred: System.QueryException: List has no rows for assignment to SObject
Any one got the solution ???
I am in the Process Builder portion. It requies an Apex Class, which the Trailhead does not specify. But I only have some irrelevant options and can't find "Give a Badge". I can't get to Apex Variable fields until I specify the right Apex Class. Anyone knows what I am doing wrong?
I had the same error and was able to resolve by creating a Thanks badge
We can't save this record because the “Completed Class Sessions” process failed. Give your Salesforce admin these details. <b>An unhandled fault has occurred in this flow</b> An unhandled fault has occurred while processing the flow. Please contact your system administrator for more information. Error ID: 676449539-99570 (1914091374)
Make sure your "Badge Name" Apex variable is of type string and set to "Thanks".
The Apex query is looking for that name in the badge table, so any mismatch will return no rows (you can see this in the debug log when setting a campaign to completed).
Like so:
09:48:00:094 SOQL_EXECUTE_BEGIN [17]|Aggregations:0|SELECT Id, Name FROM WorkBadgeDefinition WHERE Name = :tmpVar1 LIMIT 1
09:48:00:099 SOQL_EXECUTE_END [17]|Rows:0
We can't save this record because the “Completed Class Sessions” process failed. Give your Salesforce admin these details. <b>An unhandled fault has occurred in this flow</b> An unhandled fault has occurred while processing the flow. Please contact your system administrator for more information. Error ID: 676449539-99570 (1914091374)
The badge name apex variable is set to "Thanks"
Any other idea?
Thanks for the suggestion, even I have enabled work.com user in my user details, but as Xiukai mentioned we need to create a Badge called 'Thanks' in Badge object to complete this module successfully.
Thanks Xiukai and Janet.