Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

New Developer
Posts: 22
Registered: ‎12-01-2008
My Device: Not Specified

Inconsistent Stype of DateField on 4.2 and 4.6

Hi, All


I am using a DateField in both 4.2 and 4.6 platform and observe some inconsistent behavior:


new DateField("Date: ", System.currentTimeMillis(), DateFormat.getInstance(DateFormat.TIME_MEDIUM), DateField.TIME);


In 4.2, it by default has AM/PM style like 3:42PM. In 4.6 the default seemingly changes to 24 hour style like 15:42PM. In order to get consistent time display, what should we add to the code in 4.6 when using this DateField? Thanks a lot for your answers.





BlackBerry Development Advisor
Posts: 15,767
Registered: ‎07-09-2008
My Device: BlackBerry PRIV
My Carrier: Bell

Re: Inconsistent Stype of DateField on 4.2 and 4.6

Are the date format settings the same on both BlackBerry handhelds?  You can check this under Options, Date/Time on the BlackBerry handheld.
Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker