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
Shruti NigamShruti Nigam 

That operation is only allowed from within an active site

Hi i am trying to create user using method Site.createExternalUser(user, accountId, password) in trigger but whenever i try to run the code everytime i get the error That operation is only allowed  from within an active site  anyone know workaround for this.


 
AbhishekAbhishek (Salesforce Developers) 
Hi Shruti,

Please got through the below blog,

https://developer.salesforce.com/forums/?id=906F0000000AUcTIAW

It might answer your query.

Thanks.