Forum Discussion
KellyBianchi
7 years agoQrew Assistant Captain
Not entirely... I have reinstated the DoSaveAdd and retained my save button, and it works just as the native button does :) Win, win!
- JanaBaker7 years agoQrew CadetKelly...what was the final code that you implemented to make it work properly? I'm trying to accomplish the same thing. :)
- KellyBianchi7 years agoQrew Assistant CaptainRemember, this is a row of navigation, so the one you want is 'Update Info' (bolded).
// Begin button style
var text ViewOnFormThirtyOne = URLRoot() & "db/" & Dbid() & "?a=dr&dfid=31&rid=" & ;
var text bgcolor = "#4b72b0";
var text txtcolor = "white";
var text URLONE = URLRoot() & "db/" & Dbid() & "?a=er&dfid=31&rid=" & ;
var text URLTWO = URLRoot() & "db/" & Dbid() & "?a=dbpage&pagename=" & URLEncode("Service Request Form.html") & "&clist=a&rid=" & ;
var text URLTHREE = "https://vcommerce.quickbase.com/db/bnhjmd73w?";
var text URLFOUR = $URLONE & "&NextURL=" & URLEncode($ViewOnFormThirtyOne);
var text style = "style=\"text-decoration: none; background:" & $bgcolor & "; border-radius: 5px; padding: 10px 24px; margin-bottom:5px; width: auto; font-weight: normal; font-size: 12px; text-align: center; display: inline-block; color: " & $txtcolor & "; font: normal 700 24px/1 \"Calibri\", sans-serif;";
// End button style
"<div>" &
"<a " & $style & " href='" & $URLFOUR &"'>Update Info</a>" & " " &
"<a " & $style & " href='" & $URLTWO &"' target=\"new\">Print Record</a>" & " " &
"<a " & $style & " onclick='DoSaveAdd()'href='#'>Save Changes</a>" & " - JanaBaker7 years agoQrew CadetKelly this is amazing! I wont lie, some/most is over my head but i can piece it together. I'd love to mimic this if possible, but think i need a little hand holding if you dont mind?
To make sure i get it it, all of this code makes all four buttons your reference at the beginning of the post! My needs fairly close.
Upon saving, i want the user to return to Report 27 when sitting for Form 16. Currently they are being forced back to the original form, and i dont want that. How can i that into your code? I have little bits working but not all. This redirects the user to report 27:
URLRoot() & "db/" & [_DBID_LEADERS2] & "?a=q&qid=27&nv=1&v0=" & [Record ID#];
Your URLTWO goes to Service Request, mine would go to the "A-Team Dashboard"...what would i put in place of what you have here: URLEncode("Service Request Form.html"?
Then URLTHREE would just be my QB App i would assume? And for other changes i would need to make...where you have Form 31, i put what form # the buttons are sitting on? So Form 16 in this example and use [Record ID#] vs. ?
Thank you in advance!! - JanaBaker7 years agoQrew CadetKelly...to help paint a clearer picture too, the below code works to get me to the report, however, i dont know how to add the SAVE function to it. If you could help solve that issues, that would be more than enough for me as i'm sure you are busy.
// Begin button style
var text bgcolor = "#008522";
var text txtcolor = "White";
var text style = "style=\"text-decoration: none; background:" & $bgcolor & "; border-radius: 5px; padding: 10px 40px; color: " & $txtcolor & "; display: inline-block; font: normal 700 24px/1 \"Calibri\", sans-serif; text-align: center; text-shadow: none;";
// End button style
var text words="Save & Return to Change Leader Report";
var text url = URLRoot() & "db/" & [_DBID_LEADERS2] & "?a=q&qid=27&nv=1&v0=" & [Record ID#];
"<a " & $style & " href='" & $url &"'>" & $words & "</a>"
Like i said..i need this to SAVE as well as redirect to the report.
Thanks!
Jana - KellyBianchi7 years agoQrew Assistant CaptainYou might need to create a new post for this. I am not so fluent as to generate code without mixing and matching several combinations. Mark is a good one to ask, but I'd open it up to the form and see who jumps on it first :)