Forum Discussion
QuickBaseCoachD
11 years agoQrew Captain
You did not try what I suggested.
I gave you the exact code to try but it had a small syntax error. This is tested.
var text URL =
URLRoot() & "db/" & Dbid () & "?act=API_EditRecord&rid=" & [Record ID#]
& "&_fid_12="&URLEncode("Closed");
"javascript:" &
"$.get('" &
$URL &
"',function(){" &
"location.reload(true);" &
"});"
& "void(0);"
I gave you the exact code to try but it had a small syntax error. This is tested.
var text URL =
URLRoot() & "db/" & Dbid () & "?act=API_EditRecord&rid=" & [Record ID#]
& "&_fid_12="&URLEncode("Closed");
"javascript:" &
"$.get('" &
$URL &
"',function(){" &
"location.reload(true);" &
"});"
& "void(0);"
- AdminEntry8 years agoQrew CadetI have noticed that this code doesn't always work for some reason. It's not consistent, but when the button is clicked, the form or report is just refreshed but the action is not performed. Have you experienced this at all or have any idea why that would be? This happens regardless of which browser is being used.
- QuickBaseCoachD8 years agoQrew CaptainJuan
You should clearly state your question in a new post and perhaps just reference this post with a link as we have no idea what your code is. - AdminEntry8 years agoQrew CadetSorry, I was just referring to the example to which I added my comment:
URLRoot() & "db/" & Dbid () & "?act=API_EditRecord&rid=" & [Record ID#]
& "&_fid_12="&URLEncode("Closed");
"javascript:" &
"$.get('" &
$URL &
"',function(){" &
"location.reload(true);" &
"});"
& "void(0);"
I noticed that the edit action does not always get executed, although the refresh (reload) does. Sometimes the records just don't get updated.
I'll create a new post if I still need an answer. Thanks! - QuickBaseCoachD8 years agoQrew CaptainTry this
var text URL =
URLRoot() & "db/" & Dbid() & "?act=API_EditRecord&rid=" & [Record ID#]
& "&_fid_12="&URLEncode("Closed");
"javascript:" &
"$.get('" &
$URL &
"',function(){" &
"location.reload(true);" &
"});"
& "void(0); - MCFNeil8 years agoQrew CaptainYou'll need an apptoken
- QuickBaseCoachD8 years agoQrew CaptainAlso, note that you should only show the button in Edit or View mode. You cannot edit a record which does not yet exist.