Hi All,
I have requirement where i want to make a custom field called lead qualification comments as mandatory before user click on qualify lead button.
Can anyone please let me know how can we achieve this? As per initial requirement it is nice we can have pop up for the users to give a pop up to give the comments how ever it is also fine if we make this as mandatory with message lead qualification comments are mandatory.
*This post is locked for comments
Open lead entity on crm ribbon workbench and call a javascript function on click and make the custom field mandatory (Business Required)
Hi ,
As suggested above you can use custom js code inside ribbon button action. Call OOB button function inside your js function.
You can achieve this by customising the Lead Qualify button with Ribbon Workbench to call custom JavaScript code. You can set field requirement levels with the following JavaScript:
formContext.getAttribute(arg).setRequiredLevel(requirementLevel)
either pre-validation or pre-operation will be fine, but mostly pre-Operation
You need to register plugin step on "QualifyLead" message.
Check these links for more details
community.dynamics.com/.../when-to-use-the-pre-validation-stage-in-the-plugin-pipeline
If i write a plugin this plugin will be registered in pre operation or pre validation stage
hi..
you can achieve this multiple ways..
1. Customize Lead Qualify button - and call your own script before lead qualification and check comments field has any value.. if not then throw error message
here is a link to inject your code before actual event happen
mahadeomatre.blogspot.com/.../inject-your-code-before-crm-button.html
2. another option : Plugin
Write plugin on qualification.. when comments does not have any details then throw error to users.
hope this will help..
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,253 Super User 2024 Season 2
Martin Dráb 230,188 Most Valuable Professional
nmaenpaa 101,156