Default Calendar Format and Date

trsisko

Board Regular
Joined
May 20, 2008
Messages
176
I want to Default the Current Calendar Date Format to DD MM YYYY and want it to Open to Current Date?

Code:
Public CalendarVal As Date
Private Sub Calendar1_Click()
CalendarVal = Me.Calendar1.Value

Unload Me
End Sub
Private Sub UserForm_Activate()
    With UserCalendar
        .Top = Application.Top + 125
        .Left = Application.Left + 560
    End With
End Sub
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.

trsisko

Board Regular
Joined
May 20, 2008
Messages
176
Solved

Code:
If m_PCSOutput = "4v1.0" Then
UserCalendar.Show
txtInput.Value = UserCalendar.Calendar1.Value
txtInput.Value = Format(Me.txtInput.Text, "dd mm yyyy")
Unload UserCalendar

End If
If m_PCSOutput = "5v1.0" Then
UserCalendar.Show
txtInput.Value = UserCalendar.Calendar1.Value
txtInput.Value = Format(Me.txtInput.Text, "dd mm yyyy")
Unload UserCalendar
End If
If m_PCSOutput = "5av1.0" Then
UserCalendar.Show
txtInput.Value = UserCalendar.Calendar1.Value
txtInput.Value = Format(Me.txtInput.Text, "dd mm yyyy")
Unload UserCalendar
End If
If m_PCSOutput = "40v1.0" Then
UserCalendar.Show
txtInput.Value = UserCalendar.Calendar1.Value
txtInput.Value = Format(Me.txtInput.Text, "dd mm yyyy")
Unload UserCalendar
End If
If m_PCSOutput = "41v1.0" Then
UserCalendar.Show
txtInput.Value = UserCalendar.Calendar1.Value
txtInput.Value = Format(Me.txtInput.Text, "dd mm yyyy")
Unload UserCalendar
End If
If m_PCSOutput = "60v1.0" Then
UserCalendar.Show
txtInput.Value = UserCalendar.Calendar1.Value
txtInput.Value = Format(Me.txtInput.Text, "dd mm yyyy")
Unload UserCalendar
End If
End Sub
 
Upvote 0

Forum statistics

Threads
1,190,881
Messages
5,983,383
Members
439,841
Latest member
goodwillhunting

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top