Forum Discussion
CDMAutomation
3 years agoQrew Member
You can do something like this which is a slimmed-down version of your code
var customRedirectURL = "https://xxxxxxx-xxxxxxx.quickbase.com/db/xxxxxxxxx?a=dbpage&pageID=2" + "&rid=" + $(data).find('rid').text() + "&AnotherVariable=" + $(data).find('XPathToXmlNode').text();
console.log(customRedirectURL);
window.location.href = customRedirectURL;
With JQuery, you can text from XML, for a given node, XML node using the this method:
$(data).find('[XPath]').text()
Where $(data) is the API response XML
------------------------------
CDM Automation
------------------------------
LijaHarris
3 years agoQrew Cadet
Sorry, i meant that i would like https://XXXXXXXXXXXXXX.quickbase.com/db/XXXXXXXXX?a=dbpage&pageID=2&VARIABLE=C-72 instead...in case that makes more sense because i dont need the rid at all, just the formula-text field's value from that record.
------------------------------
Lija Harris
------------------------------
------------------------------
Lija Harris
------------------------------
- SimonH3 years agoQrew CadetAPI_AddRecord does not return other fields so you won't be able to use another field unless you make a separate request to get that records details using the newly generated rid
------------------------------
Simon H
------------------------------