Native time picker OK button issue

34 views
Skip to first unread message

Ivan

unread,
May 11, 2019, 11:27:11 AM5/11/19
to CodenameOne Discussions
I'm using time picker as follows
this.valueTimeText = new Picker();
this.valueTimeText.setType(Display.PICKER_TYPE_TIME);
this.valueTimeText.setDate(null);

it displays native iOS picker and when I change the value I hit OK. The value is overtaken to the destination field but picker remains visible. It does not react on Cancel button and when I hit OK again application freezes with white screen, see attachment.
What should be wrong with this component. (with light weight version it works ok)

unnamed.jpg



IDE: Eclispe
Desktop OS: Ubuntu 16.04
Simulator
Device Iphone SE 12.2

Kandy Bitxenio

unread,
May 11, 2019, 11:31:11 AM5/11/19
to CodenameOne Discussions
Hi Ivan

similar picker works fine for me on IOS, 

did you try dont send null on the line "this.valueTimeText.setDate(null);" ?

Best Regards

Ivan

unread,
May 11, 2019, 11:52:16 AM5/11/19
to CodenameOne Discussions
Thanks Kandy for quick response.
I removed the line, but still does not work

Shai Almog

unread,
May 11, 2019, 11:09:37 PM5/11/19
to CodenameOne Discussions
The picker doesn't accept null values, you need to use setTime not setDate to define the value as minutes.
Reply all
Reply to author
Forward
0 new messages