function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
MyDev TrainingMyDev Training 

Lightning message service enabled true - how to inactive this

Hi All,

My component is very simple and trying to call the Lightning component from VF page - have done this before many times, but one of the instance am facing error called - Light message service enabled true
Note: Still same code working in my developer environment but not in sandbox 

VF Page:
<apex:page standardController="Lead" sidebar="true">
    <apex:includeLightning />
   

    <div id="console">
        <div id="lightningComponent" />
    </div>
    
    <script>        
    	
        $Lightning.use("c:DownloadCalendar", function() {

            $Lightning.createComponent("c:TestingComponent", {
            
            }, "lightningComponent", function(cmp){
                //some stuff if need be
            });
            
        });
    </script>
    
</apex:page>
App :
<aura:application access="GLOBAL" extends="ltng:outApp">
    <aura:dependency resource="c:TestingComponent"/>
</aura:application>

Component:
<aura:component implements="flexipage:availableForRecordHome,flexipage:availableForAllPageTypes,force:appHostable,force:hasRecordId,lightning:availableForChatterExtensionComposer,lightning:isUrlAddressable,lightning:actionOverride" access="global">
	this is Test Component
    <aura:handler name="init" value="{!this}" action="{!c.doInit}"/>
</aura:component>

Errorconsole error
console error
 
SwethaSwetha (Salesforce Developers) 
HI,
It appears like you have set the attribute for MessageChannel in MetaData as true. You should be able to see it in VSCode under foldersuffix.messageChannel-meta.xml in the force-app/main/default/messageChannels directory.

See https://developer.salesforce.com/blogs/2019/10/lightning-message-service-developer-preview.html and 
https://www.sfdcpanther.com/lightning-message-services/ on setting isexposed property.

If this information helps, please mark the answer as best. Thank you
MyDev TrainingMyDev Training
Firstly, Thank you for your reply Swetha!
As I see, there is no LMS in my Org, is there anything causing this issue.
Am thinking to create one LMS and make isExposed= false and try - do you think , will it work?

Thank you!!!