update Contact name using Custom Contact Button
Alle Svar (4)
You need to save the contact using NSContactEntity.
NSContactAgent contactAgent;
NSContactEntity contactEntity = contactAgent.GetContactEntity(contactId);
contactEntity.SetName("contactNameHere");
contactEntity = contactAgent.SaveContactEntity(contactEntity);
// Refresh so change is immediately visible
ed.setNavigateTo("contact.main[refresh=true]")
I'm not entirely sure what you want to achieve. But you could combine EventDataDialogDefinition and the before-save trigger on Company. Here you can get user-input, and use that with the EventData object.
Hi Dan,
The statement "There is no Trigger that can be used for this scenario" is not entirely accurate. Knowing what we know so far, I will agree with Kasper. Use before save and you will get the same results you want to achieve.
If we are missing some context as to why 'no trigger can be used...', please elaborate.
Best regards.