Page 1 of 1

problem with "other" field at the end of a questionnaire

Posted: March 3rd, 2014, 5:07 am
by Anne
Hi all,
I have a problem that I can't figure out, and I suspect the solution is really simple: I have an application that has an "if other please specify"-field as the very last field. Also, when the interviewer has finished the questionnaire, I want the data entry application to close down automatically (I know that the interviewer has to travel far to reach the next respondent).

The attached application exemplifies what I want. (The "endlevel" at the CHOOSE_ONE field followed by "stop(1)" in the higher level ensures that the case is finished before saving, so that I don't get partial saved cases)

The problem is: If the interviewer opens one of the previously entered cases in modify mode, and clicks on the "other, specify" field, CSPro crashes. How do I get around this?

Anne

Re: problem with "other" field at the end of a questionnaire

Posted: March 3rd, 2014, 8:01 am
by khurshid.arshad
Dear Anne

Code: Select all

if $ <> 9 then
		endlevel;
		//stop(1);
	endif;
It will be because you are using endlevel if answer is not 9 and 9 is for others. First change your option from 1 to 9 then you can write in others. Otherwise......

i hope this answer your question.

a.

Re: problem with "other" field at the end of a questionnaire

Posted: March 4th, 2014, 4:39 am
by Anne
Dear Arshad,
I don't really understand your solution, but I did find one myself. Instead of

if $ <> 9 then
endlevel;
endif;

i made it like this
if demode() <> 2 and $ <> 9 then
endlevel;
endif;

(the annoying thing is that this is the first thing I tested, I guess I messed it up somehow when i did)

(demode() returns 2 if you're in modify mode, and 1 if you're in add mode)

Thanks anyway!

Re: problem with "other" field at the end of a questionnaire

Posted: March 4th, 2014, 5:46 am
by Anne
(and that was not a very good solution either, as now it's impossible to have anything BUT 9 in modify mode. Guess I'll have to move the demode() part up to form level, but the info in a variable and some stuff.. :) )

Re: problem with "other" field at the end of a questionnaire

Posted: March 4th, 2014, 8:01 am
by Gregory Martin
This is a bug with the multiline (or the remove-tickmarks) text box. If you disable that option, you'll see that CSPro doesn't crash.

We'll fix this for our next beta. Thanks for pointing it out.

Re: problem with "other" field at the end of a questionnaire

Posted: March 5th, 2014, 5:21 am
by Anne
Funny - the one time I believe it's my clumsy programming rather than a CSPro bug, it's a bug.

Thanks for solving it for me.This really was driving me crazy!

Anne