Page 1 of 1

CAPI Multiple Language

Posted: August 27th, 2013, 5:55 pm
by asmebarya
Dear Members
I was programming Interview questionnaire using CSPro for CAPI. I am using both English and Amharic languages in the program. I have already assigned AMH for Amharic and ENG for ENGLISH. I have also included a logic as follows to see the CAPI question and item values during the interview as per the preference of the interviewer:
Function resetLanguage()
If getLanguage() = "ENG" then
setValueSets("_ENG");
Elseif getLanguage() = "AMH" then
setValueSets("_AMH");
Endif;
end;

however I was able to change the languages in the CAPI questions but I have failed to change the languages of the value sets associated with multiple items. can any one help what logic to write in the PROC GLOBAL to choose the language when I start the CAPI data entry. Moreover, the languages of each value sets of each Item will also be changed according to the languages selected.
with best regards

Re: CAPI Multiple Language

Posted: September 3rd, 2013, 5:29 pm
by Gregory Martin
You can write a function, OnChangeLanguage, that will call your resetLanguage function. OnChangeLanguage is called by CSPro whenever the language is changed.
function OnChangeLanguage()

    resetLanguage();

end;
Alternatively, you can put the code in your resetLanguage function in an OnChangeLanguage function.

Re: CAPI Multiple Language

Posted: September 4th, 2013, 9:27 am
by user
Dear Gregory,

I can't get change language in using this function

function resetLanguage(language)

if language = 1 then // English
setvaluesets("_ENG");
setfont(valuesets,default);

elseif language = 2 then // Russian
setvaluesets("_RUS");
setfont(valuesets,"Cyrillic",12);

else // Tajik
setvaluesets("_TAJ");
setfont(valuesets,"Tajik",12);

endif;

end;

please help (with a example)

Thanks

Re: CAPI Multiple Language

Posted: September 11th, 2013, 12:24 pm
by Gregory Martin
What version of CSPro are you using? This is a new feature in CSPro 5.0.3, which was released a couple weeks ago.

Re: CAPI Multiple Language

Posted: August 5th, 2015, 11:13 am
by prabhustat
Hi George,

Will you please share the example application.

Thanks,

PP

Re: CAPI Multiple Language

Posted: August 5th, 2015, 11:16 am
by prabhustat
Can any share the example application.