This section describes the functions that are available in Relate Script. The functions can be categorized into 7 groups:
Data ConversioncharCode(...)charVal(...)format(...)formatElapsedTime(...)getFormatter(...)join(...)parseFloat(...)parseInteger(...)readCSV(...)/readCSVRows(...)split(...)toDate(...)toDateDiff(...)toDateTime(...)toTime(...)
String FunctionscompareToIgnoreCase(...)escapeJS(...)indexOf(...)lastIndexOf(...)isKey(...)matches(...)nullOrEmpty(...)pad(...)replace(...)secureHash(...)SHA1AsBase64(...)SHA1AsHex(...)substring(...)toLowerCase(...)toTitleCaps(...)toUpperCase(...)trim(...)xssHtmlSafe(...)xssSafe(...)
HTML/CSS/JavaScriptdecodeURI(...)diff(...)encodeURI(...)getButtonHTML(...)getButtonURL(...)getPopInScript(...)newJSONArray(...)B.xmlToJsonStringnewJSONObject(...)B.xmlToJsonStringputContent(...)B.pageContentscriptIncl(...)scriptTag(...)toHTML(...)toPlainText(...)
Array FunctionsfirstIndex(...)lastIndex(...)size(...)
Date/Time FunctionscurDate(...)curDateTime(...)curTime(...)set(...)/calc(...)
Mathematical Functionsavg(...)max(...)min(...)pow(...)random(...)round(...)sum(...)
Advanced FunctionsAlert FunctionscompileSASS(String Sass)createChart(...)doLookup(...)B.lookupdrugAllergyByProductID(...)B.Drug.allergyInteractionsWithdrugDrugByProductID(...)B.Drug.drugInteractionsWithdrugFoodByProductID(...)B.Drug.foodInteractionsgetCurrentNav(...)getHTTPRequester(...)B.fetchgetPageInfo()B.pageInfogetPDF(...)B.pdfgetRecentRecords(...)B.optRecentRecords,BaseRecord.optRecentRecords,User.recentRecordsgetSecurityGroup(...)B.findSecurityGroupgetUserData(...)B.sessionData,User.userDatagetZipOutput(...)B.zipisLayout()log(...)MedispannewEmail(...)B.emailreadZip(...)B.zipsendEmail(...)B.emailsendIntramail(...)sendMessage(...)B.sendMessagesendRedirect(...)B.response.sendRedirectsleep(...)
Restricted FunctionsclearCache()B.clearCacheclearLock(...)B.clearLockEnd Point request/responseB.request,B.responseexecuteQuery(...)B.executeQuerylogKeyword(...)Mckesson FunctionsprepareLookup(...)setBioImage()storeString(...)storeURL(...)Web Services