Set value of new or existing record from a value on an open form from another table

I would like to do the following:

  1. Open a form named “ServiceLog 2” (new or exiting record)

  2. Click on an inline behavior action to open another view “Expenses” and the KEY column use the value from the KEY column of the record being viewed on the open form “ServiceLog 2”. When done with the view “Expenses”, return to the open form “ServiceLog 2”.

  3. Solved

  4. Needs solving

Solved Solved
0 13 321
1 ACCEPTED SOLUTION

  • Add a ServiceLog column (physical) to the Expenses table.
  • Regenerate the column structure.
  • Expand the column structure
  • Set the column type to REF, choose Service Log table and turn on isPartOf property.
    Save the editor. When you create a ServiceLog record, you can create as many as Expense records and it will always return back to the ServiceLog form.

View solution in original post

13 REPLIES 13

What’s the question? Or do you have one?

I do not know how to solve #2.
What expression can I use to have the KEY column of “Expenses” default to the value of the KEY column of the open form “ServiceLog 2” when adding or editing a record in “Expenses” ?

( #3 and #4 were labeled as #1 and #2 but autocorrect must have changed them without me noticing )

You need to a reverse reference between the ServiceLog 2 and Expenses with isPartOf set to TRUE.

Unfortunately, I am not familiar enough with it and would need more details on how to do that.

How is your table structure for both tables? Can you give a screenshot?

  • Add a ServiceLog column (physical) to the Expenses table.
  • Regenerate the column structure.
  • Expand the column structure
  • Set the column type to REF, choose Service Log table and turn on isPartOf property.
    Save the editor. When you create a ServiceLog record, you can create as many as Expense records and it will always return back to the ServiceLog form.

That works great. Thank you so much.

You’re welcome

Hello Levent,

I have encountered something that I need to change but do not know how.

When adding a new “Related Expense” from the inline section of the Details view of ServiceLog, the label shows “Add”, which is fine ( 1st image attached ).
When adding a new “Related Expense” from the edited Form of ServiceLog, the button label shows “New Complaint”, which is not what I want ( 2nd image attached ).

I believe this is a remnant of the original structure of the sample app before I made numerous changes.
A field in the ServiceLog table was originally named “Complaint” but is now named “Subject”, but I don’t know if this is related to my issue.

I need to change the button label to be “Add” or “New” or something similar.

I have looked in many places but have not found where to make the needed changes.

Thanks, Bill

3X_f_a_fa0a398a53c1b94aa541f3beb66a5a0f9a931bad.png

3X_a_2_a2c5737c7d55a3453678f9b94e21381887d4707a.png

@Bill_Hyde
Check the Localize setting for New appearing in the ref/reverse ref columns

Success. Thanks so much.

You’re welcome.

Top Labels in this Space