pass field values to an add new record form

  • 0
  • 1
  • Question
  • Updated 11 months ago
  • Answered

I want to pass a value from a field in one table and click a button here and it'll generate a form to add a new record. In this button, I use the following formular:
URLRoot() & "db/" & "xxxxxxxx?a=API_GenAddRecordForm&apptoken=xxxxxxxxxxxxxxxxxxx"
& "&_fid_125=" & [Related Loan Application]

It redirects me successfully to the form but a field (fid is 125) in which I anticipate the value to be passes will be pre-populated in the new form did not actually doing that. Is there anything I missed?

Photo of Richard Wu

Richard Wu

  • 100 Points 100 badge 2x thumb

Posted 11 months ago

  • 0
  • 1
Is the Related Loan Application field a numeric field or a text field?
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 47,302 Points 20k badge 2x thumb
On the record that you were launching the button from, what value is in that field?
Photo of Richard Wu

Richard Wu

  • 100 Points 100 badge 2x thumb
We found that solution. The field id I was using was 125 but we found that it works with the ID of 122 because I heard that there are different types to that field: read-only , and editable. In this case, 125 is the READ-ONLY type and 122 is EDITABLE type. Is that correct?
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 47,302 Points 20k badge 2x thumb
Perhaps you were trying to update a lookup field in in the table when in fact you needed to update the reference field for the relationship. Ie the field at the top right side of the relationship.

You cannot update fields which are formula fields or lookup fields.
Photo of Richard Wu

Richard Wu

  • 100 Points 100 badge 2x thumb
OK, so in my case fid 125 is actually a Lookup field ID but fid 122 is the Reference field ID. Is that ture?
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 47,302 Points 20k badge 2x thumb
So, yes,  you need to update fid 122 then.