I have two tables linked together by unique ID numbers in an ID column in both tables. One is a top level “Employees” table and the other is a table acting as a database for various dates stored in one row for each linked ID called “Updates.” I do not want to show the “Add” option in the automatically generated inline ref view at the bottom of the EEs_Detail view if the ID already exists in the ‘Updates’ table. In this case, ideally, all that would show is an edit action in place of the system generated View and Add actions.
I’ve tried several different expressions to try and make this happen and I am coming up short. I have a feeling its because the data I am searching for, the ID, is a Ref type. Any help with the proper expression is much appreciated!!!
If I could figure out how to have it show ONLY when there are no Ref records associated to that ID, that would be ideal. Being that it tells you how many related records there are, it would seem this would be possible.
As you can see the “parts used on this work order” does not have the add button. The reason I wanted this was because the Parts that are used are added in a different view of the app however I still wanted to be able to see the parts used. I can edit the one part but I cannot add more.
There are other posts in regards to this in the community however I don’t believe there are any that ALLOW ONLY A CERTAIN AMOUT OF ADDS to a table.
I am not aware of a way to only allow one record to be added and then the add button removed. So unfortunately this post may be ignored by others because I replied to it. So you may want to ask again. If you find a way to do it please keep me updated because I have situations in my app where I would like ONLY ONE record to be added and then the add go away. I know that you could create conditions on your form that read information and then would prompt the user that they cannot add another record..
Search the community maybe there is new information in regards to this but rest assured it is not an easy thing to do.
If I remember correctly it is impossible to change this action to something you would like? It is either the system generated add action for the child table or nothing.
To be clear, “Related Updates 1” is the system generated verbiage above the child table view stating that the child table, “Updates”, has 1 related record. What would you suggest here and thank you?!
@Marc_Dillon In your 4-step approach, you suggest to use a custom action on the Parent. Do you know why we can’t hide the Child Add button? Do you think its a bug?
Theoretically, we should be able to apply to the Behavior of the Child Add button an expression like: