mobilePickDate ...

Getting into LiveCode for iOS? Ask your questions here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

mobilePickDate ...

Post by paulsr » Wed Nov 28, 2012 7:25 am

Sometimes I'm guilty of not reading all the words, but the more I read the dictionary page for mobilePickDate the more confused I am.

Here's a snippet of code:

Code: Select all

on mouseUp
   mobilePickDate "time",,,,,"cancelDone"
   put the result into tSetTime
   if tSetTime <> "cancel" then
      answer tSetTime
   end if   
end mouseUp
The LC dictionary says:

"The selected date, time or date and time are returned in the result. The value is in seconds since the UNIX Epoch.

If the picker is cancelled then cancel is returned in the result."

For me, neither of these seems to be true.

If I select a time of 14:19 and tap Done, then that is what I see in the Answer box. "14:19". Not a value in seconds. That I can live with.

But if I tap Cancel, I get a time of "07:30" showing in the answer box. I never get "cancel" and I never get any other time.

This is rather more serious. But both anomolies are confusing.

I have to think I'm doing something wrong, but I've no idea what. Can someone advise me plz...

--paul

endernafi
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 296
Joined: Wed May 02, 2012 12:23 pm
Contact:

Re: mobilePickDate ...

Post by endernafi » Wed Nov 28, 2012 9:07 am

Hi Paul,

I can confirm the first issue;
the result returns hh:mm not seconds,
maybe this is something about iOS 6 or a change in LiveCode engine.

As of the second issue, I get the cancel message.
You may consider to check your settings and/or versions of simulator & LiveCode.

Hope it helps...

Best,

~ Ender Nafi

___________________
Screen Shot 2012-11-28 at 10.01.30 AM.jpeg
Screen Shot 2012-11-28 at 10.01.50 AM.jpeg
~... together, we're smarter ...~
__________________________________________

macOS Sierra • LiveCode 7 & xCode 8

paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Re: mobilePickDate ...

Post by paulsr » Wed Nov 28, 2012 9:26 am

endernafi wrote:As of the second issue, I get the cancel message.
You may consider to check your settings and/or versions of simulator & LiveCode.
Thanks for testing this Ender. I meant to add that I'm using Livecode 5.5.2 and was testing on an iPad1 with iOS5.1

I didn't think of trying the simulator, but now that I have, I can confirm that this too returns "07:30" and not "cancel".

Bizarre!

--paul

endernafi
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 296
Joined: Wed May 02, 2012 12:23 pm
Contact:

Re: mobilePickDate ...

Post by endernafi » Wed Nov 28, 2012 9:29 am

Hm, bizarre, indeed :?
Sorry that I can't help further...

Best,

~ Ender Nafi
~... together, we're smarter ...~
__________________________________________

macOS Sierra • LiveCode 7 & xCode 8

paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Re: mobilePickDate ...

Post by paulsr » Thu Nov 29, 2012 3:57 am

This seems to be unique to Livecode 5.5.2

I've just tried it on 5.5.3 and it works as expected.

--paul

endernafi
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 296
Joined: Wed May 02, 2012 12:23 pm
Contact:

Re: mobilePickDate ...

Post by endernafi » Thu Nov 29, 2012 4:01 am

Hi Paul,

Glad to hear that your problem's solved.

Best,

~ Ender Nafi
~... together, we're smarter ...~
__________________________________________

macOS Sierra • LiveCode 7 & xCode 8

Post Reply