Java Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming LanguagesJava Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old February 27th, 2002, 09:10 AM
loneill loneill is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2002
Posts: 0 loneill User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
date and time

I have a html form and a jsp page saving the information added in the form to the database. What I want to do in my jsp page is when I am recieving the parameters from the html page I want to generate the date and the time and save them as strings seperately into my database along with the rest of my strings. Is this possible?

Reply With Quote
  #2  
Old March 1st, 2002, 07:22 AM
oscagne oscagne is offline
Java Developer
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2001
Posts: 5 oscagne User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Yeah. You can either use the database to generate them, or you can do Calendar.GetInstance(), and then use all the get methods on it to construct a string of the format you want.

Important Note: for some obscure reason january is month 0 not month 1 and it counts from there, which is very weird, but was the same in the Date class aswell. You'd have thought that they'd do it for days of the month too, but no...they come out completley fine!

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesJava Help > date and time

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap