Page 1 of 1

entering by own EA's

Posted: January 26th, 2021, 6:28 am
by hello
I need help please, how to write code for the enumerator should enter only by his assigned enumeration area
thank you

Re: entering by own EA's

Posted: January 26th, 2021, 7:47 am
by jiofack
Hi,
You can use a file for assignation. In that file will be indicated who works where.
In the menu with the interviewer code (or team code), you will check that he is working or no in the indicated EA.

Re: entering by own EA's

Posted: January 26th, 2021, 6:07 pm
by aaronw
A straightforward way to do assignments is to use an assignments lookup file with each interviewer and their assignment.

Code: Select all

Region ID | EA ID | Staff Code
01        | 01    | 0001
02        | 02    | 0002
Now, if you know the region and EA, you can call loadcase() to get the staff code:
if loadcase(ASSIGNMENT_DICT, REGION, EA) then
    // assignment is loaded in memory
endif;
If you know the staff code, you can loop through the assignments looking for the staff code with a forcase:
forcase ASSIGNMENT_DICT where A_STAFF_CODE = STAFF_CODE do
    // assignment is loaded in memory
   
break;
endfor;
If you take a look at the examples that are installed with CSPro there is an application, CAPI Census which makes use of assignments. However, I will warn you that things can get complicated quickly.

Re: entering by own EA's

Posted: January 27th, 2021, 7:13 am
by hello
thank you very much