How can I track links from Custom object fields though velocity
Hi,
I have been able to create hyperlinks on fields bought in from a Custom object, however these are not being tracked.
All efforts to try and track links have resulted in just the variable being outputted and not the link itself.
Firstly is this possible or have I wasted a full morning?
If it can be done, what am I doing wrong. I’ve tried using AI to correct me but it just keeps circling back to the same mistakes.
Everything works exactly as I want it BAR the link which comes out as just ${trackedUrl}
Is there anything obv missing or shall I simply give up?
<table style="border-spacing: 0; border-collapse: collapse; width: 100%;">
<tr>
<th style="padding: 4px; font-family: arial; border-collapse: collapse !important"><strong>Policy Number</strong></th>
<th style="padding: 4px; font-family: arial; border-collapse: collapse !important"><strong>Sponsor Name</strong></th>
</tr>
#foreach ($row in $multibillissue202511_cList)
#if ($row.dBID.contains("BEN"))
#set($dynamicURL = "https://${row.textField1}")
#set($trackedURL = $email.addTrackingToLink($dynamicURL, $row.textField1))
<tr>
<td style="padding: 4px; font-family: arial; border-collapse: collapse !important; width:100px"> ${row.policyNumber} </td>
<td style="padding: 4px; border-collapse: collapse;"><a href="${trackedURL}" target="_blank">${row.sponsorName}</a></td>
</tr>
#end
#end
</table>