Rafael Tejera wrote:
Como puedo convertir una fecha datetime a una fecha mm/dd/yyyy.
He intentado varias cosas, pero no me funciona.
Gracias de antemano,
Rafael
The language in this newsgroup is english.
I can guess on the meaning of some of the words:
convertir = convert
fecha = format
varias = various
cosas = reasons
no = don't
funciona = work
gracias = thank you
antemano = beforehand
If I understand you correctly, what you are asking for doesn't make
sense. A DateTime value doesn't have a format, so you can't convert it
from one format to another.
A DateTime value only represents a point in time, it doesn't have a
format at all; you can't display a DateTime value without first
converting it into a string.
When you convert a DateTime value into a string, you decide what format
should be used. If you don't specify any format, the default date format
of the CultureInfo.Current object is used. Whatever method you are using
to convert the DateTime value to a string has overloads that let you
specify a specific format string and/or a FormatProvider object or a
CultureInfo object.
--
Göran Andersson
_____
http://www.guffa.com