When using invokable apex and you’re passing in an object or list of objects you might get this error: “A field wasn’t found or isn’t supported for Apex action” For me it was the Billing fields on the Contract but the quick fix is basically when you build your list of records do not select…
Custom Metadata Methods
“Custom Metadata Settings” with Spring 21 finally got the same methods as their sibling “Custom Settings”. They’re basically the same except with one exception: getValues method got renamed to getInstance for Custom Metadata Settings. Also the __c got replaced with __mdt for the object name, the rest is pretty much the same except for the…
VS Code Error – Cannot read property ‘componentFailures’ of null
If you get “Cannot read property ‘componentFailures’ of null” while working with VS Code and Salesforce, it means that the org is locked. What causes an org lock? Deployments, some metadata changes, compile all classes I think will also cause this. Pop in to Dev Console and try saving something and it should give you…
Silly Flow Trick: Record Count
On a project that has me doing a lot of Salesforce Flow. I’ve seen a lot of people using a loop to do record count which was probably the only solution a couple releases ago but with all of the enhancements constantly coming it is hard to keep up. Anyhoo, this is a quick way…
How to Find Salesforce Hostnames for URL Redirects in Flow
When doing custom salesforce buttons and actions, knowing what your hostname is and/or the instance you are on is important when trying to add functionality and redirects to other custom or managed package resources. And with Lightning and Apex you have javascript and the URL methods respectively in order to determine your URL and hostname…
Setting up local Git for Mac
Anytime I get a new machine I’m reminded that setting up git is both critical and not something I do that often. This is just a reminder post to myself on what it takes to get git working just local on a Mac: Homebrew – Package manager that is a critical install for any mac…
Salesforce Test Classes never complete
I recently ran in to an issue where my test classes were running and running but never completing. It being close to Summer 20 release I thought it would resolve itself and literally let one test class running for days/over the weekend. I tried multiple sandboxes/instances so I was pretty sure it was on the…
Silly Dev Trick: Record Type Id without SOQL
Not rocket science but as usual there are a lot of bad posts on this so: Switch Opportunity for whatever object and tralala.
New Hosting
Well the time has come, we have finally moved off our old box/vm setup to a full VM environment. Previously I had a physical box rented from a colo where I had a main physical box serving as the Database and DNS server with 2 VM’s hanging off doing email and web respectfully. But times…
VS Code will not launch Chrome to Authenticate new Project
If you cancelled out or for whatever reason cannot get VS Code to launch a new browser window to authenticate your org do the following from command line: lsof -i tcp:1717 kill -9 <the process ID> Instructions are here: https://developer.salesforce.com/docs/atlas.en-us.sfdx_dev.meta/sfdx_dev/sfdx_dev_troubleshoot_cancel_auth.htm Sounds easy to remember…but then a couple months pass and here I sit wondering why I…