Click here to Skip to main content
15,894,646 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
how to get date according to country like austraila and canada,
I want only date.

thanks
Posted
Comments
DamithSL 2-Feb-15 1:19am    
in which programming language?
Sergey Alexandrovich Kryukov 2-Feb-15 1:36am    
Why? I mean, there are better approaches taking into account different time zones. If you explain the scenario, maybe some better approach could fit.
—SA

That does not make sense, you cannot get a date by country. You have to start with a date (and time) and then adjust it forwards or backwards into the required timezone. You can then display the date part only as required. You have not indicated what language or framework you are using, but they all have support for dates and times, so you should study their documentation on the subject.
 
Share this answer
 
Implement CultureInfo to get the settings as per the country
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900