Home All Groups Group Topic Archive Search About
Author
16 Jun 2006 6:36 PM
Bill Nguyen
I've been reading a confusing guideregarding Datetime format on MSDN.
All I need is to get the following output from Datetimepicker value:

MM/dd/yyyy 00:00:00 (hh:mm:ss always zero)

For example,

'06/16/2006 00:00:00'

I tried format(datetime, "MM/dd/yyyy") but it never worked!

Thanks a million.

Bill

Author
16 Jun 2006 6:55 PM
Meelis
on solution is

a) set Format to Custom
b) set CustomFormat to MM/dd/yyyy 00:00:00

use datetimepicker's Text property instead of Value property



Mex



Show quoteHide quote
"Bill Nguyen" <billn_nospam_please@jaco.com> wrote in message
news:OQb9JPXkGHA.2200@TK2MSFTNGP05.phx.gbl...
> I've been reading a confusing guideregarding Datetime format on MSDN.
> All I need is to get the following output from Datetimepicker value:
>
> MM/dd/yyyy 00:00:00 (hh:mm:ss always zero)
>
> For example,
>
> '06/16/2006 00:00:00'
>
> I tried format(datetime, "MM/dd/yyyy") but it never worked!
>
> Thanks a million.
>
> Bill
>
>
Author
16 Jun 2006 11:18 PM
Bill Nguyen
Thanks Meelis;
This works.

What are the other ways?

Bill


Show quoteHide quote
"Meelis" <m**@hot.ee> wrote in message
news:%2312fzZXkGHA.3816@TK2MSFTNGP02.phx.gbl...
> on solution is
>
> a) set Format to Custom
> b) set CustomFormat to MM/dd/yyyy 00:00:00
>
> use datetimepicker's Text property instead of Value property
>
>
>
> Mex
>
>
>
> "Bill Nguyen" <billn_nospam_please@jaco.com> wrote in message
> news:OQb9JPXkGHA.2200@TK2MSFTNGP05.phx.gbl...
>> I've been reading a confusing guideregarding Datetime format on MSDN.
>> All I need is to get the following output from Datetimepicker value:
>>
>> MM/dd/yyyy 00:00:00 (hh:mm:ss always zero)
>>
>> For example,
>>
>> '06/16/2006 00:00:00'
>>
>> I tried format(datetime, "MM/dd/yyyy") but it never worked!
>>
>> Thanks a million.
>>
>> Bill
>>
>>
>
>
Author
17 Jun 2006 9:16 AM
Meelis
hi

other way is to use iFormatProvider
DateTimePicker.Value.ToString("MM/dd/yyyy 00:00:00")

Meelis




Show quoteHide quote
"Bill Nguyen" <billn_nospam_please@jaco.com> wrote in message
news:eohbisZkGHA.1456@TK2MSFTNGP04.phx.gbl...
> Thanks Meelis;
> This works.
>
> What are the other ways?
>
> Bill
>
>
> "Meelis" <m**@hot.ee> wrote in message
> news:%2312fzZXkGHA.3816@TK2MSFTNGP02.phx.gbl...
> > on solution is
> >
> > a) set Format to Custom
> > b) set CustomFormat to MM/dd/yyyy 00:00:00
> >
> > use datetimepicker's Text property instead of Value property
> >
> >
> >
> > Mex
> >
> >
> >
> > "Bill Nguyen" <billn_nospam_please@jaco.com> wrote in message
> > news:OQb9JPXkGHA.2200@TK2MSFTNGP05.phx.gbl...
> >> I've been reading a confusing guideregarding Datetime format on MSDN.
> >> All I need is to get the following output from Datetimepicker value:
> >>
> >> MM/dd/yyyy 00:00:00 (hh:mm:ss always zero)
> >>
> >> For example,
> >>
> >> '06/16/2006 00:00:00'
> >>
> >> I tried format(datetime, "MM/dd/yyyy") but it never worked!
> >>
> >> Thanks a million.
> >>
> >> Bill
> >>
> >>
> >
> >
>
>
Author
20 Jun 2006 6:01 PM
Bill Nguyen
Thanks again

Bill
Show quoteHide quote
"Meelis" <m**@hot.ee> wrote in message
news:%2327Tp6ekGHA.1204@TK2MSFTNGP02.phx.gbl...
> hi
>
> other way is to use iFormatProvider
> DateTimePicker.Value.ToString("MM/dd/yyyy 00:00:00")
>
> Meelis
>
>
>
>
> "Bill Nguyen" <billn_nospam_please@jaco.com> wrote in message
> news:eohbisZkGHA.1456@TK2MSFTNGP04.phx.gbl...
>> Thanks Meelis;
>> This works.
>>
>> What are the other ways?
>>
>> Bill
>>
>>
>> "Meelis" <m**@hot.ee> wrote in message
>> news:%2312fzZXkGHA.3816@TK2MSFTNGP02.phx.gbl...
>> > on solution is
>> >
>> > a) set Format to Custom
>> > b) set CustomFormat to MM/dd/yyyy 00:00:00
>> >
>> > use datetimepicker's Text property instead of Value property
>> >
>> >
>> >
>> > Mex
>> >
>> >
>> >
>> > "Bill Nguyen" <billn_nospam_please@jaco.com> wrote in message
>> > news:OQb9JPXkGHA.2200@TK2MSFTNGP05.phx.gbl...
>> >> I've been reading a confusing guideregarding Datetime format on MSDN.
>> >> All I need is to get the following output from Datetimepicker value:
>> >>
>> >> MM/dd/yyyy 00:00:00 (hh:mm:ss always zero)
>> >>
>> >> For example,
>> >>
>> >> '06/16/2006 00:00:00'
>> >>
>> >> I tried format(datetime, "MM/dd/yyyy") but it never worked!
>> >>
>> >> Thanks a million.
>> >>
>> >> Bill
>> >>
>> >>
>> >
>> >
>>
>>
>
>