This is the current formula I have for the "Add button" the leads to the root cause form.
var text URLONE = URLRoot() & "db/" & [_DBID_ROOT_CAUSE] & "?a=API_GenAddRecordForm&_fid_17=" & URLEncode ([Record ID#]);
var text URLTWO = URLRoot() & "db/" & [_DBID_DAMAGE] & "?a=dr&rid=" & [Related Incident];
var text ADD =
$URLONE
& "&NextURL=" & URLEncode($URLTWO);
var text EDIT = URLRoot() & "db/" & [_DBID_ROOT_CAUSE] & "?a=dr&rid=" & [Record ID# of the Root Cause];
If([Record ID# of the Root Cause]>0, $EDIT, $ADD)
So far it's doing everything correct but to enable the user to get back to the record in the root cause for that was created.
I want the leave the user in the parent form (Damage) since that's the only form table they will have access to.
I want the button to do 2 functions if possible; 1 enable the user to create the record in root cause and 2 after the record is created have access to the record without letting the users create multiple records for that same row.
Below was a workaround I was working on last night in case I don't get the button to function the way I need it. I would rather have access to add/edit function through "Add Investigation" button.
"Root Cause Related Damage Parts Incidents2" on the right Leads the user to the record that was added once a root cause has been saved. Top row had a record added, bottom row has not had a record added.
I feel like we're so close to solving this problem!!!