• 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: Trouble comparing NSCalendarDates
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Trouble comparing NSCalendarDates


  • Subject: Re: Trouble comparing NSCalendarDates
  • From: Tito Ciuro <email@hidden>
  • Date: Mon, 15 Nov 2004 10:17:19 +0100

On Nov 15, 2004, at 09:40, j o a r wrote:

On 2004-11-15, at 09.27, Tito Ciuro wrote:

2) Later, when I need to retrieve it from disk, I call returnedValue = [[[NSCalendarDate alloc] dateWithCalendarFormat:dateData] timeZone:nil]autorelease];

No, that's not right - what do you *really* call?

The data is retrieved from a SQLite database and is a 'const char*'. So I call:

returnedValue = [[[NSCalendarDate alloc] dateWithCalendarFormat:[NSString stringWithUTF8String:data] timeZone:nil]autorelease];

What do you mean with "that's not right"? Why not?

Can you show the code that generates this log line?

NSCalendarDate* testDataDate = [NSCalendarDate calendarDate];
NSCalendarDate* verifyDate = <method which returns the value as shown above>...

NSTimeInterval interval = [testDataDate timeIntervalSinceDate:verifyDate];
NSLog(@"interval between the two: %f", interval);

Thanks,

-- Tito
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Trouble comparing NSCalendarDates
      • From: j o a r <email@hidden>
References: 
 >Trouble comparing NSCalendarDates (From: Tito Ciuro <email@hidden>)
 >Re: Trouble comparing NSCalendarDates (From: j o a r <email@hidden>)

  • Prev by Date: Re: [SOLVED] Changing the position of a NSStatusItem
  • Next by Date: Re: Can NSStatusItem contain NSTextField ?
  • Previous by thread: Re: Trouble comparing NSCalendarDates
  • Next by thread: Re: Trouble comparing NSCalendarDates
  • Index(es):
    • Date
    • Thread