I have a linktoform action that is linking to...

(Lindsey Allen) #1

I have a linktoform action that is linking to the slice. My original table that the slice is from has a ref that is not carrying over to my slice. Can anyone help?

(Reza Raoofi) #2

Have you checked the Slice and the Ref column is already on the list of selected columns in slice?

Can you clarify what you mean by the Ref column not carrying over?

(Lindsey Allen) #3

Yes that column is added.

I have a Table 1 with a customer number column that references to Table 2 which is an accounts table. I have 2 slices from Table 1. The fist slice is to record when an employee starts a job and the second records when the job finishes. I am trying to allow the user to start their job by choosing an account from Table 2 and having it link to my Start Job slice.

I tried to do this using a link to form action. When I click on the action button the customer number from the account I selected is not populating.

(Reza Raoofi) #4

You referred to 3 identities in your above comment; Accounts, Job, and Customer; I want to make sure I have understood the relationship(s) between them; do you mean Jobs table has a Ref column to Accounts table, and you want to add a new job for the selected account row?

Regardless, if you use LINKTOFORM(…) function to add a new child row to a selected parent row, it does not automatically enter a value in Ref column, unless you specify pre-fill value in the LINKTOFORM(…) function; see this document for details: https://intercom.help/appsheet/expressions/functions/linktoform

(Lindsey Allen) #5

Yes. that is what i am trying to do

(Reza Raoofi) #6

I edited my above comment in few minutes, and added a second paragraph about LINKTOFORM() did you read that too?

I think if the LINKTOFORM(…) is triggered in a selected Account row, you could pre-fill that Ref column in Jobs table with an expression similar to this: LINKTOFORM(“JobsFormView”, “Job_AccountRef”,[_THISROW].[AccountID])

That should prefill [Job_AccountRef] column in Jobs table with the existing value of [AccountID] in selected row in Accounts table.