I'm not very salesforce savvy and I need some assistance.
I need to separate the table below in two displays on the email
one for when the Type__c is Online and other when the Type__c is Inperson
I am having trouble making it work, then I tried like the code below it show me an Boolean expected error
for example is display it like this now and I want to separate by type and show two tables on for online and on for in person(where i have multiple results)
<apex:repeat var="rx" value="{!relatedTo.SDI_Rep_Trainings_Relationship__r}">
<tr>
<td>
<apex:outputText value="{!IF(!rx.Type__c == 'Online', !rx.Type__c, '')}" />
</td>
</tr>
</apex:repeat>
Edit1: Managed to fix with @cropredy tips.
but now im am getting a new error when the field is outputField see code below complains about "syntax error )". Any insight
<p>Online</p>
<table border="1" cellpadding="1" cellspacing="1" style="text-align: left;">
<tr>
<th>Type</th>
<th>Date</th>
<th>Start Time</th>
<th>End Time</th>
<th>Location</th>
</tr>
<apex:repeat var="rx" value="{!relatedTo.SDI_Rep_Trainings_Relationship__r}">
<tr>
<td>
<apex:outputText value="{!IF(rx.Type__c == 'Online', rx.Type__c, '')}" />
</td>
<td>
<apex:outputText value="{0,date,MM/dd/yy}">
<apex:param value="{!IF(rx.Type__c == 'Online', rx.Date__c, '')}" />
</apex:outputtext>
</td>
<td>
<apex:outputField value="{!IF(rx.Type__c == 'Online', rx.Training_Start_Time__c, '')}" />
</td>
<td>
<apex:outputField value="{!IF(rx.Type__c == 'Online', rx.Training_End_Time__c, '')}" />
</td>
<td>
<apex:outputText value="{{!IF(rx.Type__c == 'Online', rx.Location__c, '')}}" />
</td>
</tr>
</apex:repeat>
</table> ```
{!
- don't use any additional{!
or!
within the enclosing{! ... }
- your!rx.Type__c
meansNOT(Rx_Type__c)