Forum Discussion
QuickBaseCoachD
6 years agoQrew Captain
I have an app in the exchange called Formula URLs buttons for Dummies. It may help if you have not seen it.
When it comes to. Generalized button to do a single URL and then refresh the curr3nt page, the Syntax us this fir the refresh
"javascript:" &
"$.get('" &
$URL &
"',function(){" &
"location.reload(true);" &
"});"
& "void(0);"
If you want to execute a single URL and have a quiet pop up without a refresh, then use this syntax
"javascript:" &
"$.get('" &
$url &
"',function(){" &
"$.jGrowl('This Item has been put on PO CANCEL snooze', {life: 5000, theme: 'jGrowl-green'});" &
"});" &
"void(0);"
I know for sure all the above works.
I have a note of a post actually by Chayce, that this syntax works but I don�t know that I�ve tested it.
"javascript: {" &
"$.get('" & $DeliveryDateInOS & "');" &
"$.get('" & $PickUpDateInOS & "');" &
"$.get('" & $ProcessRec & "');" &
"location.reload();" & ;
"}"
I�m not aware of any other official documentation on how to string together multiple API calls in a low tech simple formula button. We all just keep a collection of tips and tricks.
Kirk Trachy has a great app called Magic buttons he updates every few months, so you should keep downloading that one event few months and delete you old copy.
Lastly, at the recent MPower meeting there was an app posted by actually someone who is quite new to Quick Base as a Quick Base employee and she collected about 50 tips from various internal brainiacs at QuickBase.
She plans to keep collecting tips and add them to this EOTI app.
https://team.quickbase.com/db/bpj7nsk3j
Hope this all help you or others who stumble across this post.
When it comes to. Generalized button to do a single URL and then refresh the curr3nt page, the Syntax us this fir the refresh
"javascript:" &
"$.get('" &
$URL &
"',function(){" &
"location.reload(true);" &
"});"
& "void(0);"
If you want to execute a single URL and have a quiet pop up without a refresh, then use this syntax
"javascript:" &
"$.get('" &
$url &
"',function(){" &
"$.jGrowl('This Item has been put on PO CANCEL snooze', {life: 5000, theme: 'jGrowl-green'});" &
"});" &
"void(0);"
I know for sure all the above works.
I have a note of a post actually by Chayce, that this syntax works but I don�t know that I�ve tested it.
"javascript: {" &
"$.get('" & $DeliveryDateInOS & "');" &
"$.get('" & $PickUpDateInOS & "');" &
"$.get('" & $ProcessRec & "');" &
"location.reload();" & ;
"}"
I�m not aware of any other official documentation on how to string together multiple API calls in a low tech simple formula button. We all just keep a collection of tips and tricks.
Kirk Trachy has a great app called Magic buttons he updates every few months, so you should keep downloading that one event few months and delete you old copy.
Lastly, at the recent MPower meeting there was an app posted by actually someone who is quite new to Quick Base as a Quick Base employee and she collected about 50 tips from various internal brainiacs at QuickBase.
She plans to keep collecting tips and add them to this EOTI app.
https://team.quickbase.com/db/bpj7nsk3j
Hope this all help you or others who stumble across this post.
TateForgey
5 years agoQrew Assistant Captain
I love the reload functionality and use it frequently in Formula URL fields, but I have spent longer than I would like to admit trying to get it to work when formatted as a link in a Formula Rich Text field. Is that even possible?
------------------------------
Tate Forgey
------------------------------
------------------------------
Tate Forgey
------------------------------
- MarkShnier__You5 years ago
Qrew Legend
Try this Syntax. In this example the button is toggling a checkbox field to the opposite state.
var bool NewToggle = not [Completed?];
var text URL = URLRoot() & "db/" & Dbid() & "?act=API_EditRecord&rid=" & [Record ID#]
& "&_fid_6=" & $NewToggle;
var text Words = [Account Name];
var text URL =
"javascript:" &
"$.get('" &
$URL &
"',function(){" &
"location.reload(true);" &
"});"
& "void(0);";
"<a href=\"" & $URL &"\"" & ">" & $Words & "</a>"
------------------------------
Mark Shnier (YQC)
Quick Base Solution Provider
Your Quick Base Coach
http://QuickBaseCoach.com
mark.shnier@gmail.com
------------------------------- MarkShnier__You5 years ago
Qrew Legend
actually that last line can be simplified to this
"<a href=" & $URL & ">" & $Words & "</a>"
------------------------------
Mark Shnier (YQC)
Quick Base Solution Provider
Your Quick Base Coach
http://QuickBaseCoach.com
mark.shnier@gmail.com
------------------------------- TateForgey5 years agoQrew Assistant CaptainAs usual, Coach, you pushed me in the right direction here - SUCCESS! However, I think there could be a couple of small errors in your code. (URL declared twice - that was an error for me although maybe that works in some other way and javascript outside of the anchor tag made that appear as text - when I removed the second URL declaration.) This is a fragment from a long "IF" statement in my variable (why I needed rich text in the first place) that also has a div tag around it, but I'll put in the relevant portion that I got to work in my rich text field. As ever, thank you! Now I can use this field anywhere!
var text URL = URLRoot() & "db/" & [_DBID_SHIFTS] & "?act=API_AddRecord"
& "&_fid_10=" & URLEncode ([ID])
"<a href=\"" &
"javascript:" &
"$.get('" &
$URL &
"',function(){" &
"location.reload(true);" &
"});"
& "void(0);"
&"\"" & ">" & "Add Shift" & "</a>"
------------------------------
Tate Forgey
------------------------------