Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8701895
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T02:30:49+00:00 2026-06-13T02:30:49+00:00

Today is 21.10.2012. and it is Sunday. But my VB.NET think different: Debug.Print(Weekday for

  • 0

Today is 21.10.2012. and it is Sunday.
But my VB.NET think different:

Debug.Print("Weekday for the date '21.10.2012.'is " & WeekdayName(Weekday("21.10.2012.")))
Debug.Print("Weekday for the date '21/10/2012'is " & WeekdayName(Weekday("21/10/2012")))
Debug.Print("Weekday for the date '" & DateTime.Now.Date & "'is " & WeekdayName(Weekday(DateTime.Now.Date)))

All those 3 checks give me: ‘Monday’ for weekday name!
What to do to get proper weekday names?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T02:30:51+00:00Added an answer on June 13, 2026 at 2:30 am

    This is the correct .NET way to get the weekday name of a given date:

    Dim myCulture As System.Globalization.CultureInfo = Globalization.CultureInfo.CurrentCulture
    Dim dayOfWeek As DayOfWeek = myCulture.Calendar.GetDayOfWeek(Date.Today)
    ' dayOfWeek.ToString() would return "Sunday" but it's an enum value,
    ' the correct dayname can be retrieved via DateTimeFormat.
    ' Following returns "Sonntag" for me since i'm in germany '
    Dim dayName As String = myCulture.DateTimeFormat.GetDayName(dayOfWeek)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Here are some outputs: Date.today => Mon, 25 Jun 2012 Date.today.to_formatted_s(:long_ordinal) => June 25th,
I just started learning ASP.NET MVC4 today. After reading tutorials, downloading VS 2012, and
java.util.Date date = new java.util.Date(); java.sql.Date today = new java.sql.Date(date.getTime()); //2012-03-23 java.sql.Time time =
If I do this: date1 = 2012-01-01.to_date @dates = (Date.today..Date.today + 60.days) How can
If today is Jan, 1, 2012, how to return a string of date 20120101'
Today is 24 gen 2012 for Europe. I'm using mktime to get a DateTime
I'm using moment.js 1.7.0 to try and compare today's date with another date but
Didn't change code for a month. But today (2012-11-13) started to get strange error
I want to make date by date formatter 2012-07-12 but it display like 2012-07-11
import sqlite3 import datetime today = datetime.date.today() db_name = test.db db = sqlite3.connect(db_name, detect_types=sqlite3.PARSE_DECLTYPES)

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.