Forum Discussion
JimHarrison
4 years agoQrew Champion
When the button is clicked, everything after var text url = is sent to the Quickbase server.
To do what you are trying to do would require a Code page with javaScript that would run in the browser and handle the response.
1. change button to call code page
2. use https://resources.quickbase.com/db/bq8kmgrcq/72b77352-3b9d-495e-932f-1cd9f1b15fa3 to write the code page.
I am working on something like this now. If I can figure out a simple proof of concept, I'll put up a post.
------------------------------
Jim Harrison
transparency = knowledge + understanding : The Scrum Dudes
------------------------------
To do what you are trying to do would require a Code page with javaScript that would run in the browser and handle the response.
1. change button to call code page
2. use https://resources.quickbase.com/db/bq8kmgrcq/72b77352-3b9d-495e-932f-1cd9f1b15fa3 to write the code page.
I am working on something like this now. If I can figure out a simple proof of concept, I'll put up a post.
------------------------------
Jim Harrison
transparency = knowledge + understanding : The Scrum Dudes
------------------------------
- MarkShnier__You4 years agoQrew LegendThis syntax works to use the RID of the newly created record. See if you can adapt it to your needs.
var text RID = "%%rid%%";
var text AddShipment = URLRoot() & "db/" & Dbid() & "?a=nwr";
var text EditShipment = URLRoot() & "db/" & Dbid() & "?a=er&rid=" ;
var text URL =
$AddShipment
& "&rdr=" & URLEncode($EditShipment) & $RID;
"<a class='SaveBeforeNavigating' data-replaceRid=true style=\"text-decoration:none; background: #4b7097; border-radius: 5px; color: #ffffff; display: inline-block; padding: 0px 0px 0px 0px; width:100px; text-align: center; text-shadow: none; border: 2px solid #030404; font-size: 12px \"href='"
& $URL
& "'>Save and Display in Edit Mode</a>"
NOTE: The %%RID%% does not seem to like being URLEncoded.
The user would need to push this button (Rich Text formula field type) to save the record, not the regular save button.
If you can lanch off a buton that suffixed the URL with
&ivf=1,
that would suppress the native save buttons forcing the user to use this special button.
------------------------------
Mark Shnier (YQC)
mark.shnier@gmail.com
------------------------------- JimHarrison4 years agoQrew ChampionHey Mark,
Are you referring to this?
https://resources.quickbase.com/db/brf7iunzv?a=dr&rid=6&rl=hvz
------------------------------
Jim Harrison
transparency = knowledge + understanding : The Scrum Dudes
------------------------------- MarkShnier__You4 years agoQrew LegendSorry, I meant to post some working code. I will also edit my post above.
var text RID = "%%rid%%";
var text AddShipment = URLRoot() & "db/" & Dbid() & "?a=nwr";
var text EditShipment = URLRoot() & "db/" & Dbid() & "?a=er&rid=" ;
var text URL =
$AddShipment
& "&rdr=" & URLEncode($EditShipment) & $RID;
"<a class='SaveBeforeNavigating' data-replaceRid=true style=\"text-decoration:none; background: #4b7097; border-radius: 5px; color: #ffffff; display: inline-block; padding: 0px 0px 0px 0px; width:100px; text-align: center; text-shadow: none; border: 2px solid #030404; font-size: 12px \"href='"
& $URL
& "'>Save and Display in Edit Mode</a>"
NOTE: The %%RID%% does not seem to like being URLEncoded.
------------------------------
Mark Shnier (YQC)
mark.shnier@gmail.com
------------------------------