www.webdeveloper.com
Results 1 to 2 of 2

Thread: Quick question on switching from VB 08 to VB 10

  1. #1
    Join Date
    May 2010
    Posts
    93

    Quick question on switching from VB 08 to VB 10

    Hey guys just a quikc question thats probably right in front of me. I am trying to set a CustomVaildator for date input and i know the old way you would set the CustomerVaildator and set the Property and then you could go to the Object drop-down list and then choose CustomValidator and then you could select the Event from the drop down list....where the hell our the object and event drop down list in VB 2010? Or is there a new way to do this? again I am trying to just make it where if someone types in a date my regular format is MMM DD , yyyy so if someone puts in sgkjsgjswi it doesnt crash...

    thanks for any help!

  2. #2
    Join Date
    Jan 2003
    Location
    Dundee, Scotland
    Posts
    1,367
    Hi,

    this is wrong forum as the CustomValidator control is ASP.NET however you can just use a RegularEpressionValidator to validate your date.

    I've not test this expression (source here http://forums.asp.net/t/1480183.aspx )

    Code:
      ValidationExpression="(0[1-9]|[12][0-9]|3[01])/(0[1-9]|1[012])/\d{4}"
    regards

    Ribs

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles