Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

how to convert a string to date

Steven M
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
my recordStore has timesheet records stored with fields delimited with "^". a sample record may look like "1^2^time entry desc^1:30^2:30^1/1/2005"

when i pull that record up for editing, i extract the data and get something like 1:30 = start time, 2:30 = end time. now i need to set the dateField inputs on the form to 1:30 and 2:30. because these values are string, and dateField's setDate() method only wants to accept date, i need to convert the strings to date, but how? casting won't work and i can't seem to find an libraries that will do the job.

any ideas?

What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!