Click here to Skip to main content
14,430,927 members
Rate this:
Please Sign up or sign in to vote.
See more:
I used a calender controller to insert a date to one of my forms used in ASP.Net. But the text-box shows the date as a short date. All I want is to display the date as a long date for better viewing.

I used VB 2005 with ASP.Net 2.0

1 solution

Rate this:
Please Sign up or sign in to vote.

Solution 1

Format the date with the ToString function, with the Long Date format string: "F"
There is a list of the format codes here: Formatting a DateTime for display - format string description[^]
Chiranthaka Sampath 17-Dec-11 3:29am
But my dear friend all I want is to display the date in full in the web browser not in the vb console! Please try to solve my question!
OriginalGriff 17-Dec-11 4:21am
Use your brain: the Console.Writeline was to show you what the output would look like. I do not know what your control names are, where in your code you are putting this, etc., etc., etc..
Chiranthaka Sampath 17-Dec-11 22:39pm
Ah thanx !

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

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100