• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Daylight Saving bug in Numbers
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Daylight Saving bug in Numbers


  • Subject: Re: Daylight Saving bug in Numbers
  • From: HEB <email@hidden>
  • Date: Sun, 03 Apr 2016 16:01:22 +0200

Since "only" Yvan responded to this thread, shall I interpret that as the problem being well-known, and that it is meaningless to report this yet one more time?
Too difficult for Apple to solve?

(Thanks Yvan for your good answers!)


______heb____________________________
Harald E Brandt     http://bragit.com



On 2016-03-30, at 21:22, Yvan KOENIG <email@hidden> wrote:


Le 30 mars 2016 à 19:41, HEB <email@hidden> a écrit :

There is clearly a Daylight Saving bug when communicating with Numbers. I don't know if this has been reported earlier or not, so I'll describe it here:

How to reproduce:

Preliminary: Assume you already have a spreadsheet file in Numbers open (version 3.6.1), and that the first cell in the first row is formatted as a date.
FYI: In Sweden we use international date format: YYYY-MM-DD.

tell application "Numbers"
tell table 1 of sheet 1 of front document
--Note: Daylight Saving Time started 2016-03-27
set value of cell 1 of row 1 to "2016-03-25"
return short date string of (get value of cell 1 of row 1)
end tell
end tell

--> "2016-03-24"

I.e, what I get back is a whole day earlier!!
In Numbers, the cell is "2016-03-25 00:00:00", i.e correct according to what I set it to. 
But when I get the date via AS then it is interpreted as one hour earlier, which means it becomes the day before.

If, on the other hand, I set the date after the start of sumertime, e.g "2016-03-28", then it behaves correctly.

We can see that it appears to be one hour difference between Numbers and Applescript if we set a date object directly with:
date "2016-03-25"
which in Swedish expands to: 
date "fredag 25 mars 2016 00:00:00"
We get:
tell application "Numbers"
tell table 1 of sheet 1 of front document
--Note: Daylight Saving Time started 2016-03-27
set value of cell 1 of row 1 to date "fredag 25 mars 2016 00:00:00"
return (get value of cell 1 of row 1) --In this case we get the complete date, including the exact time.
end tell
end tell

--> date "fredag 25 mars 2016 00:00:00"

I.e, it appears to work well know, but if we look into Numbers, the cell is now:
"2016-03-25 01:00:00"
I.e, it is one hour ahead! I did set it to midnight, but it became 1 o'clock in the morning!
If I do the same thing but on the 28 March, then it will remain midnight also in Numbers.

I know this problem for years but I'm tired to file reports with no result.


On 2016-04-01, at 17:49, Yvan KOENIG <email@hidden> wrote:
...
So, if we need to be able to extract the value which we inserted, my understanding is that we must insert a string value and use the auxiliary column with the formula =""&A1

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Daylight Saving bug in Numbers
      • From: Shane Stanley <email@hidden>
  • Prev by Date: Re: What is AcroExt?
  • Next by Date: Re: Daylight Saving bug in Numbers
  • Previous by thread: Re: Daylight Saving bug in Numbers
  • Next by thread: Re: Daylight Saving bug in Numbers
  • Index(es):
    • Date
    • Thread