Skip to Content

How to update Campaign in Sales Order

Dear Experts,

While editing Salesorder based on some conditions, I want to create /Edit campaign to a specific value.

In event aftermodify of SO,Iam trying as below :

var campaign : elementsof SalesOrder.BusinessTransactionDocumentReference;
--campaign.BusinessTransactionDocumentRelationshipRoleCode -- Readonly
--campaign.BusinessTransactionDocumentReference -- Readoinly

But this is not allowing to create a campaign .Same issue in Edit also .

Plesae help in resolving

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Feb 15 at 02:39 PM

    I suggest you look to see if there's already a pre-existing reference --- you might be able to follow the association chain to set the ID, e.g. currentSalesOrder.CampaignReference.BusinessTransactionDocumentReference.ID.content or something of the ilk.

    Add comment
    10|10000 characters needed characters exceeded

    • Resmi,

      Is your solution in the same namespace as the SalesOrder business object? If so, you might be out of luck. Is the campaign ID editable in the front end from the salels order?