Forum Discussion
ChayceDuncan2
6 years agoQrew Cadet
Sorry - I copied some of that from a different example
var text field = URLRoot() & "db/" & [_DBID_REQUESTS] & "?a=API_GetFieldProperties&fid=9";
"javascript: {" &
"$.get('" & $field & "',function(data,success) {" &
"var count = data.getElementsByTagName('field')[0].getElementsByTagName('choices')[0].children.length);" &
"$.get('" & URLRoot() & "db/" & [_DBID_REQUESTS] & "?a=API_EditRecord&rid=" & [Record ID#] & "&_fid_10='" + count);"
"});" &
"}"
In this example - you would do an Edit Recod call to store the value in the number of field choices - I put fid 10 for demo
Chayce Duncan | Director of Strategic Solutions
(720) 739-1406 | chayceduncan@quandarycg.com
Quandary Knowledge Base
var text field = URLRoot() & "db/" & [_DBID_REQUESTS] & "?a=API_GetFieldProperties&fid=9";
"javascript: {" &
"$.get('" & $field & "',function(data,success) {" &
"var count = data.getElementsByTagName('field')[0].getElementsByTagName('choices')[0].children.length);" &
"$.get('" & URLRoot() & "db/" & [_DBID_REQUESTS] & "?a=API_EditRecord&rid=" & [Record ID#] & "&_fid_10='" + count);"
"});" &
"}"
In this example - you would do an Edit Recod call to store the value in the number of field choices - I put fid 10 for demo
Chayce Duncan | Director of Strategic Solutions
(720) 739-1406 | chayceduncan@quandarycg.com
Quandary Knowledge Base