Long error messages in Android version

Discussions about CSEntry
Post Reply
Keith Tomlin
Posts: 56
Joined: March 23rd, 2014, 9:30 am

Long error messages in Android version

Post by Keith Tomlin »

Hi - in my data entry system I'm asking interviewers to select regions, zones and villages from value set lists. When interviewers have completed these screens I'd then like to have an error message to confirm their selections which reads (for example):-

Please confirm that you are in:-
Region : OROMIA
Zone : JIMMA
Village : BEYEDA

I've used \n to get the items to display on separate lines, but find that on the Android screen I only get the first two lines i.e.
Please confirm that you are in:-
Region : OROMIA...

Is there any way to expand the part of the error message in which the text of the message is displayed?

Many thanks

Keith
Gregory Martin
Posts: 1796
Joined: December 5th, 2011, 11:27 pm
Location: Washington, DC

Re: Long error messages in Android version

Post by Gregory Martin »

This is odd. What is the screen resolution of the devices that you are using? On my phone, I can view error messages with many lines, and I can touch to scroll the lines if they exceed the screen size. See here:
Attachments
Screenshot_2014-07-01-12-33-53.png
Screenshot_2014-07-01-12-33-53.png (129.79 KiB) Viewed 4318 times
Keith Tomlin
Posts: 56
Joined: March 23rd, 2014, 9:30 am

Re: Long error messages in Android version

Post by Keith Tomlin »

Hi Greg

The layout of my error message is a little different to yours. In mine all of the text is in the blue upper portion, and below that are Yes and No options in response to the message (rather than having a heading in blue and the text of the message below in black). This blue portion on mine is completely fixed in size, and truncates the message if it is more than two lines long. Below is the code that I have written. This does not use the newline option, but I still run into the same problem because the text of the error message is more than two lines long.

NB - the code for the error message below is all on one line.

Many thanks

Keith

PROC Q104
postproc
alpha regionlabel;
alpha zonelabel;
alpha woredalabel;
alpha kebelelabel;
if $="" then
errmsg ("Please type in the name of the gote");
reenter;
else
if demode()= add then
regionlabel=getlabel(Q100,Q100);
zonelabel=getlabel(Q101,Q101);
woredalabel=getlabel(Q102,Q102);
kebelelabel=getlabel(Q103,Q103);
errmsg("Please confirm that you are in Region: %s, Zone: %s, Woreda: %s, Kebele: %s, Gote: %s",strip(regionlabel),strip(zonelabel),strip(woredalabel),strip(kebelelabel),Q104) select("Yes",continue,"No",Q100);
endif;
endif;
Gregory Martin
Posts: 1796
Joined: December 5th, 2011, 11:27 pm
Location: Washington, DC

Re: Long error messages in Android version

Post by Gregory Martin »

Ah okay, I see what the problem is. You were using an errmsg with buttons, whereas in my test I didn't add any buttons. They message text gets displayed in a different place when you use buttons, and you're right that it was truncated after two lines, which is the default Android behavior for these dialog boxes.

I've modified the code to customize the dialog box so that it will display more than two lines. This will be out in the next beta release.

Thanks for reporting the problem.
Keith Tomlin
Posts: 56
Joined: March 23rd, 2014, 9:30 am

Re: Long error messages in Android version

Post by Keith Tomlin »

Thanks Greg, that would be fantastic, as this message will be an important method for our enumerators to confirm their location.

All the best

Keith
Post Reply