Discussions

 View Only
  • 1.  Redirect to new record

    Posted 08-10-2022 12:03
    Edited by JENNIFER PASCHAL 08-10-2022 12:15
    Hello -

    I am using a formula URL to create a new record in a table. The intent of the button is to essentially copy certain aspects of a record to a new record. (note: I know there are a couple native copy functionalities within QB but their limitations do not work for this use case) I would like to redirect the user to the new record  in EDIT view but I am not sure what to add to the formula to do so.

    Currently, the end of my formula includes this (which redirects to the record on which the button was clicked):  & "&rdr="&URLEncode( URLRoot() & "db/" & Dbid() & "?a=doredirect&z=" & Rur

    How do I need to alter my formula to redirect to the created record in EDIT view so they can make any changes needed from the original record?



    ------------------------------
    Thanks in advance,
    Jennifer Paschal
    ------------------------------


  • 2.  RE: Redirect to new record

    Posted 08-10-2022 12:29

    If you are using API_AddRecord and include the peramwter

    &disprec=1

    then it will display the record that it just created. 


    If you have any trouble with this post your whole formula



    ------------------------------
    Mark Shnier (Your Quickbase Coach)
    mark.shnier@gmail.com
    ------------------------------



  • 3.  RE: Redirect to new record

    Posted 08-10-2022 14:04
    Edited by JENNIFER PASCHAL 08-10-2022 14:04
    Thank you! Okay so this change took me to the home page of the app. How would i have it open the created record in edit mode or even just the add form with the field info passed through so the user can make changes before officially saving the record?

    Here is my formula
    URLRoot() & "db/" & [_DBID_INTAKE] & "?a=API_AddRecord"

    //copy as is
    & "&_fid_8=" & [Initiative Type]
    & "&_fid_7=" & [Requesting Business Unit]
    & "&_fid_117=" & [Initiative Name]
    & "&_fid_743=" & [Simplified Description]
    & "&_fid_16=" & [Problem Statement]

    //Change Request? = Yes
    & "&_fid_474=" & "Yes"

    //copy as is
    & "&_fid_116=" & [Transformation Office Approval]
    & "&_fid_359=" & [Arch Roadmap]
    & "&_fid_11=" & [Channel(s) Impacted]
    & "&_fid_12=" & [Product(s) Impacted]
    & "&_fid_17=" & [Customer Experience(s)]
    & "&_fid_18=" & [Employee Experience(s)]
    & "&_fid_19=" & [Quantifiable Benefit Estimate]
    & "&_fid_20=" & [Benefit Calculation]
    & "&_fid_137=" & [Detailed Description]

    //test record = Yes --remove after go live
    & "&_fid_856=" & "Yes"

    //redirect
    & "&rdr=" &URLEncode( URLRoot() & "db/" & Dbid() & "?a=doredirect=1" & Rurl())

    ------------------------------
    Thanks in advance,
    Jennifer Paschal
    ------------------------------



  • 4.  RE: Redirect to new record

    Posted 08-10-2022 14:10
    If you want to just land the user on an input form, use a different API

    URLRoot() & "db/" & [_DBID_INTAKE] & "?a=API_GenAddRecordForm"

    //copy as is
    & "&_fid_8=" & [Initiative Type]
    & "&_fid_7=" & [Requesting Business Unit]
    & "&_fid_117=" & [Initiative Name]
    & "&_fid_743=" & [Simplified Description]
    & "&_fid_16=" & [Problem Statement]

    //Change Request? = Yes
    & "&_fid_474=" & "Yes"

    //copy as is
    & "&_fid_116=" & [Transformation Office Approval]
    & "&_fid_359=" & [Arch Roadmap]
    & "&_fid_11=" & [Channel(s) Impacted]
    & "&_fid_12=" & [Product(s) Impacted]
    & "&_fid_17=" & [Customer Experience(s)]
    & "&_fid_18=" & [Employee Experience(s)]
    & "&_fid_19=" & [Quantifiable Benefit Estimate]
    & "&_fid_20=" & [Benefit Calculation]
    & "&_fid_137=" & [Detailed Description]

    //test record = Yes --remove after go live
    & "&_fid_856=" & "Yes"

    ------------------------------
    Mark Shnier (Your Quickbase Coach)
    mark.shnier@gmail.com
    ------------------------------



  • 5.  RE: Redirect to new record

    Posted 08-10-2022 14:17
    Thank you :) That does exactly what I need

    ------------------------------
    Thanks in advance,
    Jennifer Paschal
    ------------------------------