How to read the date format specified in the Regional Settings and change it ?

Posted on 2006-03-23
Last Modified: 2010-05-01
I need to ensure that the date format in Regional Settings is "dd/mm/yyyy". How do I find out the date format in Regional Settings and change it if necessary ?

Question by:rajesh_khater
    LVL 8

    Accepted Solution

    LVL 14

    Assisted Solution

    MsgBox Format(Date, "Short Date")
    'Returns current system date in the system-defined short date format

    MsgBox Format(Date, "Long Date")
    'Returns current system date in the system-defined long date format

    See the following link 2 set Regional Setting:~

    LVL 1

    Assisted Solution

    Search for "Force Date Format" on this site, the solucion is a function that gets what you need.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Free Trending Threat Insights Every Day

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
    I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
    As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
    Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

    779 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

    13 Experts available now in Live!

    Get 1:1 Help Now