Skip to main content
Question

Add a new record on a custom form AND view that record on the same custom form once the record is saved.

  • August 17, 2018
  • 0 replies
  • 50 views

I have a magic button to add a new record in a specific form ' URLRoot() & "db/" & [DBID XXX] & "?a=API_GenAddRecordForm&_fid_21=" & URLEncode ([XXX]) & "&dfid=18".  It works to add the record, however when I save the new record I am taken to the default form.  How can I save and view the new record on the custom form - "dfid=18" in this case - instead of the default form?
This topic has been closed for replies.

QuickBaseJunkie
Forum|alt.badge.img+15
You're half way there! You just need to specify the next url at the end of your formula.

URLRoot() & "db/" & [DBID XXX] & "?a=API_GenAddRecordForm&_fid_21=" & URLEncode ([XXX]) & "&dfid=18 &" & "nexturl=" & URLEncode(URLRoot() & "db/" & [DBID XXX] & "?a=dr&dfid=18&rid=" & [Record ID#])



Alas, when you add a record,  you do not know the Record ID# until it gets created.  So I'm stumped on that one.


  • Author
  • Registered
  • August 20, 2018
The button is located on the form of the parent record.  That "nexturl=" parameter is something I was not aware of.  I'd used "&rdr=" before in other use cases, but that opens up a lot of possibilities. Thanks!  That is a big help in and of itself beyond this specific issue.