By Dan McGhan
December 20, 2019
For example, in the When section of a dynamic action, there’s an Event setting that specifies which browser event to listen for. Although there are many events available to choose from, some uncommon events are not listed, to avoid clutter. What if you need to work with one of the missing events or a custom event emitted by a library you’re using? In either case, the workaround is simple: Use the Custom option.
When you select the Custom option for Event, a Custom Event field is displayed where you can enter any event name you’d like. If you’d like to work with multiple events, separate the event names with a space.
In the example below, I’m using the Custom event option and specifying two events, one of which is a custom event. I’m also using a jQuery Selector to select all inputs on the page that have a type attribute equal to
Here’s an example where the condition checks to ensure that two different items are null.
fadeout method to fade out the Alternate Number field on the page instead of just disabling it.
closest method traverses up to the item’s wrapper to ensure that the label is hidden, along with the actual input field.
The two attributes I want to discuss here are Function and Global Variable Declaration and Execute when Page Loads. I’ll touch on the File URLs attribute in the last part of this article.
varwill not leak into the global scope.
Here’s an example of how to use these attributes to declare a function and execute it when the page loads:
Because I’m not accessing the DOM and don’t need to access
options object that will contain any relevant default options. In the body of the function, you modify any supported options and return the
options object. APEX will invoke the function while initializing the component and use the options you’ve specified.
The help for this attribute varies for each component and provides an example to get you started. Here’s an example from a chart region:
I’ll show you how to move the
Next, navigate to Shared Components -> Static Application Files. Click Upload File >, and use the dialog box to upload the file. When the file is uploaded, you should see it displayed in Static Application Files.
Illustration by Wes Rowell