We use scopes to call a method in the headless client like this:
underlying method is called from a form!
fv_headlessclient = plugins.headlessclient.createClient("mod_DM_server",null,null,null);
if (fv_headlessclient != null && fv_headlessclient.isValid()) {
fv_headlessclient.queueMethod(null, "scopes.modDMserver.mod_DM_server_sendMails", [vObj], doDone);
}
the callback-method is: doDone, which is also present on the form.
this works fine here.