Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 82002

How to Use CRUD with Xrm.WebApi.online.executeMultiple

$
0
0

Hi community,

When i use the Xrm.WebApi.online.executeMultiple i have this error :

this is my code :

function CreateReqs(_id, _price) {
    var reqObject = {};
        reqObject.Entity = { "@odata.type": "Microsoft.Dynamics.CRM.opportunityproduct",
                                                         "@opportunityproduct.id": _id };
        reqObject.Price= _price;                        
        reqObject.getMetadata = function () {
            var metadata = {
                boundParameter: "entity",
                operationType: 2,
                operationName: "Update",
                parameterTypes: {
                    "Entity": {
                        typeName: "Microsoft.Dynamics.CRM.opportunityproduct",
                        structuralProperty: 5
                    },
                    "Price": {
                        typeName: "Edm.Deciaml",
                        structuralProperty: 1
                    }            
                }
            };
            return metadata;
        }
        
    return reqObject;
}

Best


Viewing all articles
Browse latest Browse all 82002

Latest Images

Trending Articles



Latest Images