For Entity forms don't want to show Entity Image or Navigation items, Microsoft provided this setting in Form Properties.
Open Form in customization,
Click on Form properties.
In Display tab you will see two sections - Page navigation & Image,
Page navigation - Show navigation Items is default checked.. means show navigation items, when any record opened in this form. If you uncheck this checkbox, then navigation items will not be shown.
Image - Show image in Form is also default checked, Entity Image will be shown on form, when it is unchecked, entity image will not be shown for record when this form is used to open record.
In CRM Email template, you cannot add record id, but sometime we need to send GUID in email or need to send record URL which will contain record ID/ GUID.
To Add GUID in email template,
1. Create one text attribute in Account or contact entity.. say Account GUID.
2. Add this attribute on form, so that we can able to use it in JavaScript.
3. Add following JavaScript code on form load.
function getRecordId() {
var accountGuid = Xrm.Page.getAttribute('new_accountguid').getValue()
if (Xrm.Page.ui.getFormType() == 2 && accountGuid == null) {
Here I am getting account id and updating in custom attribute. We can do this only if existing record is opened.
If want to populate this custom Account GUID attribute on save of account record, then need to create custom plugin and register on Post-Save method. Make sure.. this plugin is not going into Loop by adding some condition like if new_accountguid is null then only execute & update account.
4. Now open or create email template for account and add this custom attribute in email template
5. Now use this email template for Account..
Another option will be by updating Template body XML. but for this need to update template XML using SQL query.
CRM stores templates in Template table.
to get particular template,
select Body from Template where Title='Account Reconnect'
Email template body is represented in XML and xml is look like
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
</xsl:choose><![CDATA[,</p> <p>We have not heard from you for a while. We wanted to check in and make sure that you are still having a great experience using our product(s). We have asked ]]><xsl:choose>
<xsl:when test="account/ownerid/@name">
<xsl:value-of select="account/ownerid/@name" />
</xsl:when>
<xsl:otherwise>a customer service representative</xsl:otherwise>
</xsl:choose><![CDATA[ to contact you next week to get your feedback on the product(s) you are currently using and to give you details about our upcoming products.</p><p>?]]><xsl:choose>
and updated back template body using SQL statement
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
update Template set Body='<?xml version="1.0" ?><xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"><xsl:output method="text" indent="no"/><xsl:template match="/data"><![CDATA[<p>Dear ]]><xsl:choose><xsl:when test="account/name"><xsl:value-of select="account/name" /></xsl:when><xsl:otherwise>Valued Customer</xsl:otherwise></xsl:choose><![CDATA[,</p> <p>We have not heard from you for a while. We wanted to check in and make sure that you are still having a great experience using our product(s). We have asked ]]><xsl:choose><xsl:when test="account/ownerid/@name"><xsl:value-of select="account/ownerid/@name" /></xsl:when><xsl:otherwise>a customer service representative</xsl:otherwise></xsl:choose><![CDATA[ to contact you next week to get your feedback on the product(s) you are currently using and to give you details about our upcoming products.</p><p>?]]><xsl:choose><xsl:when test="account/accountid"><xsl:value-of select="account/accountid" /></xsl:when><xsl:otherwise></xsl:otherwise></xsl:choose><![CDATA[?</p><p> </p> <p>Thank you.</p>]]></xsl:template></xsl:stylesheet>' where Title='Account Reconnect'