Discussions

 View Only
  • 1.  URL Button to edit record and return to original launch screen

    Posted 06-22-2022 01:00
    Hello,
    I'm trying to get a url button from a report to edit a record and return to the original launch point. This is my code. The edit works, but I cant get the screen to refresh. 

    var text ReturnToOriginalLaunchPoint = "https://xxx.quickbase.com/db/xxx?a=q&qid=74";
    URLRoot() & "db/"& Dbid()
    & "?act=API_EditRecord&apptoken=xxxxx
    &rid=" & [Record ID#]
    & "&_fid_6=" & URLEncode(1)

    & "&NextURL=" & URLEncode($ReturnToOriginalLaunchPoint)

    I get an error message..

    This XML file does not appear to have any style information associated with it. The document tree is shown below.
    <qdbapi>
    <action>API_EditRecord</action>
    <errcode>0</errcode>
    <errtext>No error</errtext>
    <rid>660</rid>
    <num_fields_changed>0</num_fields_changed>
    <update_id>1655872xxxx</update_id>
    </qdbapi>


    ------------------------------
    Jamil Idun-Ogde
    ------------------------------


  • 2.  RE: URL Button to edit record and return to original launch screen

    Posted 06-22-2022 03:50
    I think what you need is detailed here:

    https://community.quickbase.com/blogs/evan-martinez1/2019/12/06/using-ampzamprurl-and-rdr-in-formula-url-fields

    Specifically

    URLRoot() & "db/" & [_DBID_TASKS] & "?a=API_EditRecord&rid=" & [Record ID#] & "&_fid_7=Approved" & "&rdr="&URLEncode(URLRoot() & "db/" & Dbid() & "?a=doredirect&z=" & Rurl())

    Make sure you tick Open Target in Same Page

    ------------------------------
    Pete James
    ------------------------------



  • 3.  RE: URL Button to edit record and return to original launch screen

    Posted 06-22-2022 15:36
    Thank you so much Pete.
    It worked!

    ------------------------------
    Jamil Idun-Ogde
    ------------------------------