Often when users of EpIData send in files to epidata.dk for help it turns out that chk files are created more complex than actually needed. One example of this:
From a chk file (opened in the editor, not in "Add/revise") example: labelblock LABEL label_q01 8 dog 14 Horse 21 "lazy tiger" end end
v1 missingvalue 99 comment legal use label_q01 end
In this situation only the values 8 14 21 and 99 plus "blank=missing" can be entered. If the v1 block is changed to:
v1 mustenter missingvalue 99 comment legal use label_q01 end
Only the values 8 14 21 and 99 can be entered.
So there would be no reason to test in a "after entry .... end" block like this:
v1 mustenter missingvalue 99 comment legal use label_q01 after entry if (v1 <> 8) and (v1 <> 14) and (v1 <> 21) and (v1 <> 99) then help "Wrong value entered" goto v1 endif end end
One other aspect of this is that sometimes people define the same values in a RANGE and LEGAL and COMMENT LEGAL and MISSINGVALUE Any value should only be in one of these definitions.
regards Jens Lauritsen