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
kaylonkaylon 

DML inside a RemoteAction method

Can a record be inserted from a RemoteAction method?

The records type does not match the controller type.

 

Thanks.

kiranmutturukiranmutturu
Yes you can insert . there is no DML restriction in this. Are you getting any issues?
jordi vosjordi vos

Note that the remote action can't access the controler where it's located in.

We're actualy using a lot of remote actions at my current project and they work like a charm.

We're building a application mainly in javascript and about all the interactions to to the salesforce database are handled by remote actions.