I also had some luck running an mx.data.create function with an mx.data.action inside.
mx.data.create({
entity: "YourApp.entity",
callback: function (obj) {
obj.set("EntityName", entityValue),
mx.data.action({
params: {
applyto: "selection",
actionname: "MyApp.Microflow",
guids: [obj.getGuid()],
},
});
alert("Object created on server");
},
error: function (e) {
alert("Could not commit object:", e);
}
});
Good Luck!
Bryan
Hi,
If the object is persistent you can specify an XPath constraint to retrieve it.
mx.data.action({
params: {
applyto: "set",
actionname: "Application.Log",
xpath: "//MyFirstModule.Object",
constraints: "[id=XXXX]",
origin: this.mxform
},
callback: function() {
}
}, this);
Hope this helps,
Andrej