Hello, I am French and we write dates : "dd/MM/yyyy". I like to save dates in a SQL DB and the format is "yyyy/MM/dd". How can I cut a date every "/"? I like to have an array of String... Tk you very much Greg
posted 14 years ago
Probably the simplest way would be to use the split() method of String. For example:
That will print out:
You would need to reverse the array, but since there are always three elements that should be no problem.
Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius - and a lot of courage - to move in the opposite direction. - Ernst F. Schumacher