Rodney Vinyard - .NET & SQL Developer
When all is said and done, more will be said than done
My Links
Home
Archives
Links
Contact
Syndication
Login
News
Recent Comments
Here is one more related topic to explain in a bet...
by susheel
'gCol' is not declared. It had not mentioned gCol ...
by Sinan
I am about to complete a university thesis on this...
by irfan
I like the way you start and then conclude your th...
by online bag store
Very good...thank you....it helped a lot
by vijay
<< Allow only one instance of any MDI child form in your MDI application
|
Home
|
convert xml string to dataset & WriteXmlSchema to string >>
C# Format Date
C# Format Date
_attribute =
" effectiveDate=\""
+
string
.Format(
"dd/MM/yyyy"
, _value).ToString() +
"\""
;
Comments
#
re: C# Format Date
Jeferson Nascimento
Code above is Wrong....
string.Format("{0:dd/MM/yyyy}", _value).ToString();
Posted @ 3/9/2007 7:32 PM
#
re: C# Format Date
ryan(philippines)
this code is very useful.:)
Posted @ 3/25/2007 10:07 PM
#
re: C# Format Date
zahir
the above code is wrong.
you have to use like this:
formateddate=DateTime.Now.ToString("dd / MMM/ YYYY");
or
("dd-MM-yy") or ("dd-MMM-YYYY");
Posted @ 4/3/2008 12:43 AM
#
re: C# Format Date
dkl
Thanks very much
Posted @ 8/14/2008 4:25 AM
#
re: C# Format Date
AL
Thanks a lot for this code and comments. :D
Posted @ 10/6/2008 1:53 PM
#
re: C# Format Date
lotto
DateTime dt = DateTime.Now;
string dateString = String.Format("{0:MM/dd/yyyy}",dt)
Posted @ 2/17/2009 8:26 AM
#
re: C# Format Date
Nripin
Thanks Zahir !!!
Posted @ 7/3/2009 6:41 AM
#
re: C# Format Date
noha
thanks zahir
Posted @ 9/3/2009 6:59 AM
#
re: C# Format Date
Yasir
Thanks, it worked
Posted @ 10/10/2009 4:01 AM
#
re: C# Format Date
Ganesh
string date = string .Format("DD/MMM/YYYY",DateTime.Now);
it will show output value as "DD/MM/YYYY"
Posted @ 12/19/2010 5:53 AM
#
re: C# Format Date
snehal
good code but instead of dd-mm-YYYY
write dd-mm-yy
or dd-mm-yyyy
Posted @ 5/30/2011 7:04 AM
#
re: C# Format Date
mobi001
thanks ...
Posted @ 6/26/2011 11:39 AM
#
re: C# Format Date
vikas
thanks it helped me
Posted @ 3/10/2012 12:05 AM
#
re: C# Format Date
Mary
I am a beginner only in csharp..!!
I wanna know how to check the string entered is in dd-MM-yyyy format??
Pls help..
Posted @ 3/18/2012 7:20 PM
#
re: C# Format Date
k
Convert.ToDatetime(date).ToDstring("dd / MMM/ yyy")
Posted @ 5/15/2012 4:37 AM
#
re: C# Format Date
Ben
I have an issue regarts to the formating to date.
I want it to display "01/Jan/2013" but it display "01-Jan-2013"
This is the code that is use:
DateTime.Now.ToString("dd/MMM/yyyy")
How can i rectify the issue
Posted @ 1/27/2013 8:33 PM
#
re: C# Format Date
Dineshprabhu
Console.WriteLine(dt.ToString("d",
CultureInfo.CreateSpecificCulture("en-NZ")));
Posted @ 2/14/2013 10:31 PM
#
re: C# Format Date
N.Siva
String to yyyy-MM-dd date format:
Example:
TxtCalStDate.Text = Convert.ToDateTime(objItem["StartDate"]).ToString("yyyy/MM/dd");
Posted @ 2/17/2013 6:57 AM
#
re: C# Format Date
Jordan Shoes
so interesting ,thanks very much
Posted @ 3/2/2013 12:17 AM
#
re: C# Format Date
Lehlohonolo Letaoana
Thanks a lot N.Siva!
Posted @ 3/29/2013 9:17 AM
#
re: C# Format Date
susheel
Here is one more related topic to explain in a bettor way
down vote
see this http://susheelonline.com/date-time-format-in-c/
here you can get list of format for date and time in C#
still have issue please talk to me
susheel3010@gmail.com
Posted @ 5/2/2013 12:54 AM
Post A Comment
Title:
Name:
Email:
Website:
Comment:
Verification:
Enter the code shown above
Remember Me?