Solved

Converting Date to day

Posted on 2006-06-22
4
245 Views
Last Modified: 2010-04-23
i want to switch 2005-10-10 to what day it did correspond on the calendar. Using .NET Framework 1.1.

Best Regards.
0
Comment
Question by:TheSonics
  • 2
4 Comments
 
LVL 10

Expert Comment

by:vadim63
ID: 16962474
Day of the week, day of the year?
0
 

Author Comment

by:TheSonics
ID: 16962488
Day of week.
0
 
LVL 10

Expert Comment

by:vadim63
ID: 16962549
Dim d As Date = "10/10/2005"
        Dim dWeek As String
        Select Case d.DayOfWeek
            Case 1
                dWeek = "Mon"
            Case 2
                dWeek = "Tue"
            Case 3
                dWeek = "Wed"
            Case 4
                dWeek = "Thu"
            Case 5
                dWeek = "Fri"
            Case 6
                dWeek = "Sat"
            Case 7
                dWeek = "Sun"
        End Select
        MsgBox(dWeek)
0
 
LVL 37

Accepted Solution

by:
Harisha M G earned 250 total points
ID: 16962563
MsgBox(Now().ToString("ddd"))

Instead of Now(), you can have your date
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

773 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