How to conditionally enable Add/New button fo...

How to conditionally enable Add/New button for inline reference table?

I have two tables, “report” and “detail”, which is a ref table to “report”. A report can have many details: detail[report_id] = report[id] .

I would like the user to be able to add further report details via the inline view, provided the report has not been flagged as “reviewed” (report[reviewed] is a boolean). I’ve tried adding a condition to the Add action for the detail table, but I can’t seem to snag the value of the reviewed column for the report record to which the detail records are related.

Even though the Expression Assistant recognizes the names of columns in the detail table, it does not really seem to have access to them. I’ve tried something like this, which works if you click the Test button in the Expression Assistant, but it doesn’t actually work for the Add action. NOT(ANY(SELECT(report[reviewed], [id] = [report_id])))

or

ANY(SELECT(report[reviewed], [id] = [report_id])) = false

Note that this sort of condition works for the Edit and Delete buttons once you have selected a detail record from the inline view.

Any advice?

0 3 1,151
3 REPLIES 3
Top Labels in this Space