Have you tried a
Refresh Window [ Flush cached join results ]
script step, after the close window step?
Yes and unfortunately it didn't work.
What you are looking at is a found set of records in your list view. Adding a new record will not automatically change what records are present in that found set. Perform a find or use Go To Related Records to update the found set as part of a script performed when the user finishes creating the new records such as when they click the button to commit.
Another option would be to use a portal to list the records. The list of related records in the portal should update automatically when a new record is added.
Yes, I understand that I am looking at a found set of records. I just tried your suggestion of using Go To Related Records. I added this step to the commit button on the modal window but to the found set was not updated. I also tried a refresh after the Go To Related Records but this also didn't work. I would prefer not to have to use a portal if possible. Any idea what I am doing wrong?
I would guess that your GTRR step was either not set up correctly, was performed from the wrong context or there isn't the right relationship in place to produce the results that you need.
The GTRR would need to be performed from a specific layout (one based on the correct table occurrence needed for your relationship to the table on which your layout listing the records is listed and should be performed in the window where you have listed these records.
So if you have this relationship:
Where Table 2 stores the records being listed, the script might look something like this:
Select Window [//select the window used to list the records]
Go To Related Record [Show only related records; From table: Table1; Using layout: "Table1" (Table1) ]
Go To Related Record [Show only related records; From table: Table2; Using layout: "Table2" (Table2) ]
The first GTRR sets up the needed "context" in order for the second GTRR to correctly pull up the original list of records plus your newly added record.
Thanks for the idea. I just tried something else that seems to work and is easier than what you mentioned.
When the commit button on the modal window is pressed, the script commits the record, closes the window , and then I added:
Find Matching Records (Extend; "using my foreign key").
When I tested it, it worked. Do you think this is good way to solve this or are there "hidden" issues that I may not see right now?
There are no hidden issues that I know of and it's a much simpler option.
Thanks for the super quick response!!!!!