You need to sign in to do that
Don't have an account?

Link to record does not work in visualforce email template
Hi
i am using the following code for opportunity link in visualforce email template:
Link to Opportunity: <apex:outputlink value="{!LEFT($Api.Partner_Server_URL_140,FIND('.com',$Api.Partner_Server_URL_140)+4)+relatedTo.Id}"><apex:outputtext value="{!LEFT($Api.Partner_Server_URL_140,FIND('.com',$Api.Partner_Server_URL_140)+4)+relatedTo.Id}"/></apex:outputlink>
in test email it works fine but in actual email it does not displacy {!ralatedTo.Account.Name} and link is also converting to secure.force.com
https://abc.secure.force.com/0061K00000bNllxQAC
any help is much appreciated.
Thanks
i am using the following code for opportunity link in visualforce email template:
Link to Opportunity: <apex:outputlink value="{!LEFT($Api.Partner_Server_URL_140,FIND('.com',$Api.Partner_Server_URL_140)+4)+relatedTo.Id}"><apex:outputtext value="{!LEFT($Api.Partner_Server_URL_140,FIND('.com',$Api.Partner_Server_URL_140)+4)+relatedTo.Id}"/></apex:outputlink>
in test email it works fine but in actual email it does not displacy {!ralatedTo.Account.Name} and link is also converting to secure.force.com
https://abc.secure.force.com/0061K00000bNllxQAC
any help is much appreciated.
Thanks
I think the apex:outputText value to be corrected to {!ralatedTo.Account.Name} ( from relatedTo.Id )
Also, this might help,
https://salesforce.stackexchange.com/questions/40072/vf-email-template-detail-link
Thank You,
Rajesh Adiga P.