I am getting the error:
The requested operation is invalid. Server Response: EHS Checksheet Entries failed: Could not find a property named 'crda1_EHSChecksheetEntry' on type 'Microsoft.Dynamics.CRM.crda1_ehschecksheetentry'
Here is a snippet of the code which is causing the error:
ForAll(
ReportChecksheets As CurrentChecksheet,
Collect(
BBPCountData,
{
Count: CountIf(
'EHS Checksheet Entries' As Entry,
Entry.AuditDate >= bbp_report_Start.SelectedDate,
Entry.AuditDate <= bbp_report_End.SelectedDate,
Entry.'EHS Checksheet'.Name = CurrentChecksheet.Name // This is the problem line
)
}
)
)
I am trying to count the records in 'EHS Checksheet Entries' that match a specified one (CurrentChecksheet), using the lookup column 'EHS Checksheet' and the Name column for the related record.
'EHS Checksheet Entries' is related many-to-one to 'EHS Checksheets'. But the error message makes no sense to me.
When I create a text label to test this out and use the following for the Text:
CountIf('EHS Checksheet Entries','EHS Checksheet'.Name = "Process")
it properly counts the ones that go towards the "Process" checksheet and gives me the count. So why doesn't it work for the other code? I have tried testing using "Process in the original code too and still, same error message.

Report
All responses (
Answers (