• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 348
  • Last Modified:

VB help

Please can you help with the attached file.

The userform has a calendar object, however the ouput into the textbox (TxtCompletion) is in US format mm/dd/yyyy

Please can you help me change this to UK format dd/mm/yyyy

I did look in properties but was unable to locate, so assume this needs to be done in VB.

Thanks for your help.
  • 2
1 Solution
Just format the calendar control value
Private Sub Calendar2_Click()
    TxtCompletion.Value = Format(Calendar2.Value, "dd/mm/yyyy")
End Sub

Open in new window

Kiwi-123Author Commented:
For some reason when I try that it comes back as an error?

Could it be because I have another calendar (Calendar1) in another userform.
Kiwi-123Author Commented:
Sorry my mistake, many thanks for your help!
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now