Results 1 to 2 of 2

Thread: Masked Text Box - Date Mask 00/00/0000

  1. #1

    Thread Starter
    Addicted Member Smartacus's Avatar
    Join Date
    Oct 2009
    Location
    Deep South, USA
    Posts
    196

    Masked Text Box - Date Mask 00/00/0000

    Hi All,

    I suppose most of us know that there is a bug in VS2008 Masked Textbox that Microsoft apparently can not or will not fix (at least I have not found where they have solved it except patch code in C#) when the MTB is bound.

    Entering a date such as 02/15/1964 automatically parses the leading zero giving a date result of something like 21/01/964 after lost focus. I have tested it unbound and it works fine.

    Anyone came up with a solution? I have used date validate and Custom Mask.

    What I thought may have been a work around it is in keyup event that if position 1 is < 9 then insert a zero, but it goes right back to the result. If I do a debug.print or message box though it shows the zero.
    ***************************************************
    Smartacus comes packaged "As Is With No Warranty"

    ************* Useful Links ******************
    FAQs: Index / Database Development / .NET CodeBank /
    Before Posting Here...MSDN

    MZTools (I love this tool when using VB6 - Free) /

  2. #2
    Member cyberM's Avatar
    Join Date
    Mar 2009
    Location
    Croatia , Zagreb
    Posts
    61

    Re: Masked Text Box - Date Mask 00/00/0000

    In my mask text boxes works fine..Can you explain better ?
    If you satisfied add to reputation





    PhotoResizer GDI+Shape form,shape inside

Tags for this Thread

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