how to write date in this format in c# -


i have date 9/27/2010 8:17:28 pm want write them in format 27 september 2010 8:19 pm how can write in format using c#

use custom datetime format string:

string res = mydate.tostring("d mmmm yyyy h:mm tt", cultureinfo.invariantculture); 

update:

as @jon hanna mentions, format month title case (september), if want in example (september), can add tolowerinvariant() method call.


Comments

Popular posts from this blog

drupal - using views argument in the view tpl.php file -

silverlight - Applying a style to ItemContainerStyle in C# -

php - Posting PHPBB Forum Thread/Post info in a website -