Results 1 to 4 of 4

Thread: Monthview showing today's date

  1. #1

    Thread Starter
    Fanatic Member The_Grudge's Avatar
    Join Date
    Jan 2005
    Location
    Canada
    Posts
    836

    Monthview showing today's date

    The following code works,

    VB Code:
    1. Monthview1.Value = Now

    But how can I set it so that "NOW" does not display a datetime. I want the date in a format like "YYYY/MM/DD".

    I tried the "Dateformat property" of the Monthview control but notta.
    I am getting ready to try trimming the time of the end manually, but I'm certain there is an easier way.

  2. #2
    Frenzied Member David.Poundall's Avatar
    Join Date
    Sep 2002
    Location
    Robin Hood Land
    Posts
    1,457

    Re: Monthview showing today's date

    try...

    VB Code:
    1. Monthview1.Value = Format(Now, "yyyy/mm/dd")
    David

    Learn the Rules so that you know how to break them properly.

    Printing dll dBTools MZTools Winsock API WinsockVB More Winsock SGrid2 MSChart Mail2Web

    If you have found this thread useful then read this

  3. #3

    Thread Starter
    Fanatic Member The_Grudge's Avatar
    Join Date
    Jan 2005
    Location
    Canada
    Posts
    836

    Re: Monthview showing today's date

    Thanks

    ...and I call myself a VB Programmer.

    Ikes...

  4. #4
    Frenzied Member David.Poundall's Avatar
    Join Date
    Sep 2002
    Location
    Robin Hood Land
    Posts
    1,457

    Re: Monthview showing today's date

    I am suprised that the Monthview didn't do the conversion itself. It must know the format of what is coming in (the Now function) - and the format of what it needs.

    Another hole to be plugged.

    David

    Learn the Rules so that you know how to break them properly.

    Printing dll dBTools MZTools Winsock API WinsockVB More Winsock SGrid2 MSChart Mail2Web

    If you have found this thread useful then read this

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width