Subscribe, Unsubscribe MessageChannel in LWC, Aura and Visualforce Page in Salesforce
GitHub Source Code: https://github.com/magulan/Salesforce-Message-Channel SampleChannel.messageChannel-meta.xml: <?xml version=”1.0″ encoding=”UTF-8″?><LightningMessageChannel xmlns=”http://soap.sforce.com/2006/04/metadata”> <masterLabel>SampleChannel</masterLabel> <isExposed>true</isExposed> <description>This is a sample Lightning Message Channel.</description> <lightningMessageFields> <fieldName>variable1</fieldName> <description>Variable 1</description> </lightningMessageFields> <lightningMessageFields> <fieldName>variable2</fieldName> <description>Variable 2</description> </lightningMessageFields></LightningMessageChannel> Aura: Component: <aura:component implements=”flexipage:availableForAllPageTypes” access=”global”> <aura:attribute type=”String” name=”ReceivedMessage”/> <lightning:messageChannel onMessage=”{!c.onMessageReceive}” scope=”APPLICATION” type=”SampleChannel__c” aura:id=”sampleMessageChannel”/> <div class=”slds-box slds-theme–default”> <lightning:button label=”Publish” onclick=”{! c.publish }”/><br/><br/> … Continue reading Subscribe, Unsubscribe MessageChannel in LWC, Aura and Visualforce Page in Salesforce
Copy and paste this URL into your WordPress site to embed
Copy and paste this code into your site to embed