Forum Discussion

JoshuaCase's avatar
JoshuaCase
Qrew Cadet
5 years ago
Solved

URL Button to auto-complete form

Is there a way to add a button that will edit a record with "pre-planned" data?  Looking for a quick approval system for an app I created for employee overtime requests.  This button would be only acc...
  • SergioSanchez1's avatar
    5 years ago
    Hello Joshua

    Absolutely, please modify he following code as your best convenience:

    -----
    var text URL= URLRoot() & "db/" & [your table ID] & "?act=API_EditRecord"
    & "&apptoken=your app token"
    & "&_fid_field##=yes"
    & "&_fid_field##=Approved";

    "javascript:" &"$.get('" &$URL &"',function(){" &"location.reload(true);" &"});" 
    ​​-----

    Remember to use URL type field, and have it : Display as a button on forms and reports". 

    ------------------------------
    Sergio Sanchez
    ------------------------------