Conditional Formatting within a portal.
Trying to highlight a row when it is the Creation_Time is 20 minutes different from the Creation_Time above.. See attachment
GetNthRecord will work on related records like that.
Not sure on the calculation using the GetNthRecord I want the interval for 15 minutes or more. Example...
9:57 am to 11:43 am is more the 15 mins.. So 11:43AM should highlight.
11:43 am to 2:06 pm is more than 15 mins so 2:06PM should highlight...
GetNthRecord(ReportData::Creation_Time;1) - Last(ReportData::Creation_Time) > 1
ReportData::Creation_Time - GetNthRecord(ReportData::Creation_Time; Get(ActivePortalRowNumber) -1)
Edit: Also does not work
2nd parameter should be absolute row number, so maybe
ReportData::Creation_Time - GetNthRecord(ReportData::Creation_Time; Get(RecordNumber) -1) > Time ( 0 ; 15 ; 0 )
Big oops. That's so embarrassing I went back and changed my reply.
Also, because it's in a portal, it actually has to be Get(ActivePortalRowNumber)
instead of Get(RecordNumber).
Edit: The above does not work either.
Wow, I missed portal.
return "active" (selected) row number, so same value in all portal rows at a time.
It would be Get(CalculationPortalRowNumber), but there is no such function. And Get(RecordNumber) in conditional formatting of objects in portal calculate it in portal context, so it worked as expected.
Get(RecordNumber) in conditional formatting of objects in portal calculate it in portal context,
No, I don't think so. It calculates in the context of the parent TO.
If you want to use the portal row's number in conditional formatting, you need to define an unstored calculation field in the child table returning Get (RecordNumber) and use that instead of Get (RecordNumber) directly.
I really thought as you wrote, but I wondered it worked just now on FM17. Since I tested it with current table portal
See for yourself:
This example file can help you?
Retrieving data ...