Parse mm/dd/year into 3 textboxes |mm||dd||year|

Posted on 2004-11-14
Last Modified: 2010-04-24
I have a database with dates stored in one field named Date in this format mm/dd/year.
I need my application to parse this date into 3 different textboxes when my program reads from this field:
mm = txtmonth.text
dd = txtday.text
year = txtyear.text

Thanks for any suggestions or code.
Question by:Matrix1000
    LVL 3

    Accepted Solution

    Dim split As String() = YourDateField.Split("/".ToCharArray())
    txtmonth.Text = split(0)
    txtday.Text = split(1)
    txtyear.Text = split(2)
    LVL 4

    Assisted Solution

    Or you can use
    yourDate.DayOfWeek = dd
    yourDate.Month =mm
    yourDate.Year = yyyy

    Featured Post

    Enabling OSINT in Activity Based Intelligence

    Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

    Join & Write a Comment

    I'm currently working for a company where I have to upgrade over 50 VB6 programs to VB.NET 2008.  So far I'm about half way through, and I've learned quite a few tricks that drastically improve the performance of VB.NET apps. Because there are a…
    Article by: jpaulino
    XML Literals are a great way to handle XML files and the community doesn’t use it as much as it should.  An XML Literal is like a String ( Literal, only instead of starting and ending with w…
    Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
    Here's a very brief overview of the methods PRTG Network Monitor ( offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

    731 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now