Hello,
I am migrating our current forms from Gravity forms integrated into our Dynamics CRM to Dynamics Marketing. We currently have a form that has radio buttons with different options. When the user selects one of the radio button options, it triggers whatever item they choose to populate a hidden field under "Topic" in our CRM.
I need help on how to accomplish this using Dynamics Marketing please.
Thanks,
Mariah
Yes, thank you. It did work for us!
Hi Mariah,
Could it work for you?
Regards,
Clofly
If you had found any answer helped, please kindly mark as verified to close the thread, it would be really appreciated.
Hi Mariah,
In Dynamics Marketing, we can accomplish it with javascript.
The script will execute after form is rendered.
MsCrmMkt.MsCrmFormLoader.on('afterFormLoad', function (event) { var radiobtnList = document.querySelectorAll('input[type="radio"]'); for (var i = 0; i < radiobtnList.length; i ) { radiobtnList[i].addEventListener('change', function () { if (this.checked) { document.getElementsByTagName("input")[0].value = this.nextSibling.innerText; } }) } })
In my marketing form, the Topic field is the first field, so index number of document.getElementsByTagName("input")[0.value is 0, please adjust the number based on your environment.
Result:
The topic field of new lead has been set to text of checked radio button option.
Regards,
Clofly
André Arnaud de Cal...
292,160
Super User 2025 Season 1
Martin Dráb
230,962
Most Valuable Professional
nmaenpaa
101,156