So, here is where I am now:
'date validation
If Not IsDate(ITTIssueDate.Value) Then
MsgBox "Please enter all dates in the following format: DD-MMM-YYYY"
Exit Sub
Else
IID = Format(ITTIssueDate.Value, "DD-MMM-YYYY")
End If
If Not IsDate(TenderDueDate.Value) Then
MsgBox "Please enter all dates in the following format: DD-MMM-YYYY"
Exit Sub
Else
TDD = Format(TenderDueDate.Value, "DD-MMM-YYYY")
End If
Fnd = "[insert ITT number]": Rep = ITTNumber.Value
Fnd2 = "[insert ITT title]": Rep2 = ITTTitle.Value
Fnd3 = "[insert date]": Rep3 = IID
Fnd4 = "(insert date)": Rep4 = TDD
Fnd5 = "(insert Subcontract Formation Specialist name)": Rep5 = FormationSpecialist.Value
First the code looks to see if it's actually a date that's input. If not, it forces the the user to put in a date. Then I try to assign the value of the text box to a certain variable and dictate the format "DD-MMM-YYYY". But, whenever the date is spit out it is not DD-MMM-YYYY, rather M/D/YY. Any ideas?
Got it working here, this makes more sense and is more efficient too:
If Not IsDate(ITTIssueDate.Value) Then
MsgBox "Please enter all dates in the following format: DD-MMM-YYYY"
Exit Sub
End If
If Not IsDate(TenderDueDate.Value) Then
MsgBox "Please enter all dates in the following format: DD-MMM-YYYY"
Exit Sub
End If
Fnd = "[insert ITT number]": Rep = ITTNumber.Value
Fnd2 = "[insert ITT title]": Rep2 = ITTTitle.Value
Fnd3 = "[insert date]": Rep3 = Format(ITTIssueDate.Value, "DD-MMM-YYYY")
Fnd4 = "(insert date)": Rep4 = Format(TenderDueDate.Value, "DD-MMM-YYYY")
Fnd5 = "(insert Subcontract Formation Specialist name)": Rep5 = FormationSpecialist.Value