• 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: Initial values for date fields possible?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Initial values for date fields possible?


  • Subject: Re: Initial values for date fields possible?
  • From: Sam Barnum <email@hidden>
  • Date: Mon, 15 Dec 2003 08:11:07 -0800

// Getting today's date is an easy one:

NSTimestamp searchRangeMax = new NSTimestamp();

// getting one week ago can be done with NSTimestamp.timestampByAddingGregorianUnits(),
// if accuracy isn't crucial (w.r.t daylight savings, etc)


NSTimestamp searchRangeMin = searchRangeMax.timestampByAddingGregorianUnits(0, 0, -7, 0, 0, 0);



On Monday, December 15, 2003, at 06:54 AM, Muggianu, David wrote:

Hello,

I would like to fill date fields ("from" and "to") with initial values. It
should be possible, that searches are done for entries of the last week til
today.


Therefore I think, I need an initial value for "from" (f.e. current date
minus seven days) and for "to" (current date).


How can I do this?

Many thanks in advance for all answers.

Bye, David
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Initial values for date fields possible?
  • Next by Date: Re: NullPointerException only after first call to batchFetchRelationship
  • Previous by thread: Initial values for date fields possible?
  • Next by thread: Re: Initial values for date fields possible?
  • Index(es):
    • Date
    • Thread