Skip to main content The Trailblazer Community will be unavailable from 2/1/2025 to 2/2/2025. Please plan your activities accordingly.
Hello,

I have the following code in my VF Email Template:

<apex:outputText rendered="{IF(!relatedTo.RecordTypeId = '012a00000018Ens')}">{!relatedTo.id}</apex:outputText>

The relatedTo type here is "Case".  The goal here is to have the VF Email Template send to an external Contact when an agent makes a new public comment on the Case.  The above format does absolutely nothing when I do verify merge field tests.

I have also tried the following:

<div style="{IF(!relatedTo.RecordTypeId = '012a00000018Ens')},'display:block;','display:none;'">{!relatedTo.id}</div>

Again, nothing.

I have read other articles that say to include an exclamation point in front of the "IF", but when I do that I get the following error:

Error: Incorrect parameter type for function 'not()'. Expected Boolean, received Text

I really need to get this to work asap. 

Any help?

 
1 answer
  1. Jan 20, 2015, 10:50 AM

    Try this :

    <apex:outputText rendered="{!relatedTo.RecordTypeId == '012a00000018Ens' }">

    {!relatedTo.id}

    </apex:outputText>

     
0/9000