Tag Archives: survey

Confirmit array If statement

Quick code to check a selection of variables for a code of 2 which is a fail. Checks all of the top variables  [‘qnr_main_section1_PF’……..etc. If any of these are marked as code 2 and if so set var qnT = f(‘qnr_overall_QA_PF’); as 2 which is overall fail Else set to 1 which is pass var qIDsToCheck = […]

Read More

Merge string and respid

Merging a string with the respid of the respondent to create a unquie ID which is targetable by a survey, email or reportal report. Create a new DP rule and select the survey and add in a filter, the field we are populating will be “userid” so make sure this field is empty using the […]

Read More

Confirmit Apps

Confirmit Apps Currently Confirmit have two core apps out. Capi Confirmit CAPI (Computer Assisted Personal Interviewing) is a module of Confirmit Horizons, an end-to-end solution that enables you to manage each and every step of the survey lifecycle, from multi-mode survey creation and deployment to panel management, data processing, online reporting, analysis, and alerting. Link […]

Read More

Field Length using Java – Confirmit

While using an open text list, this will set the max length of each of the fields in the list, as standard confirmit will set the length for all of the fields with one box, use this if each one differs in length. My open text list is called ContactDetails document.getElementById(“ContactDetails2_Main”).maxLength = “20“; document.getElementById(“ContactDetails2_Alt“).maxLength = “25“; […]

Read More

First character from a string

First character from a string To capture the first value of a string in a Confirmit script node, use the script below. var str : String = f(“qnr_new_details_1“).get(); var firstLetter : String = str.charAt(0); var suranmeinital = (f(‘qnr_new_details_2‘) + “, ” + firstLetter); surnameinitalout.set(suranmeinital); This is taking 2 values (First name and surname) and making […]

Read More

Masking

Code Masking Code masking will let you hide answers of a question based on a previous question, for example – f(‘q14′).get()==’1’ ? set(‘1′,’2′,’3’) : set(‘4′,’5′,’6’) If the user has selected option 1 from question q14 this multi will show answers 1,2,3 else it will show answers 4,5 and 6 Code masking on a question set(‘1′,’2′,’3’) […]

Read More

Count answered questions

Simple way to add a number value to count the number of questions answered. This will then place the count answer into a variable. Here is a simple script. var qanswer = f(‘qnr_countquestions‘); var i = 0 ; if(f(‘qnr_questionsone‘).toBoolean()){   i = i+1; qanswer.set(i);       } if(f(‘qnr_questiontwo‘).toBoolean()){   i = i+1; qanswer.set(i);   […]

Read More