title: Excel Date Picker Date format
body: <p>I am experiencing an issue where the date picker in excel appears to be using the US version of a date that i am searching for.</p>
  
  <p>I am trying to check if a work sheet exists where in a range of cells a date exists that fall in the parameters of DTpicker1 and DTpicker2. </p>
  
  <p>Can anyone advise how i can force the code to check the date in a uk format? </p>
  
  <pre><code>Private Sub CommandButton1_Click()
  Dim s As Worksheet, wb As Workbook
  UserForm1.Hide
  For Each s In Worksheets
      If CBool(Application.CountIfs(s.Range("E11:E37"), "&gt;" &amp; 
      Format(DTPicker1.Value, "dd/mm/yy"), _ s.Range("E11:E37"), "&lt;" &amp; 
  Format(DTPicker2.Value, "dd/mm/yy"))) Then
          If wb Is Nothing Then
              s.Copy
              Set wb = ActiveWorkbook
          Else
              s.Copy after:=wb.Worksheets(wb.Worksheets.Count)
          End If
      End If
  Next s
  
  If wb Is Nothing Then
      MsgBox ("No Records Found")
  Else
      wb.SaveAs Filename:="Technicians - Batch Record Report" &amp; Format(Date, 
  "ddmmyyyy"), _
            FileFormat:=xlOpenXMLWorkbook, CreateBackup:=False
  End If
  End Sub
  </code></pre>
  
  <p>Credit to @Jeeped who got me this far!</p>
  
  <p>Update: Code works by reversing date formats:</p>
  
  <pre><code>Private Sub CommandButton1_Click()
  Dim s As Worksheet, wb As Workbook
  UserForm1.Hide
  For Each s In Worksheets
      If CBool(Application.CountIfs(s.Range("E11:E37"), "&gt;" &amp; 
      Format(DTPicker1.Value, "mm/dd/yy"), _ s.Range("E11:E37"), "&lt;" &amp; 
  Format(DTPicker2.Value, "mm/dd/yy"))) Then
          If wb Is Nothing Then
              s.Copy
              Set wb = ActiveWorkbook
          Else
              s.Copy after:=wb.Worksheets(wb.Worksheets.Count)
          End If
      End If
  Next s
  
  If wb Is Nothing Then
      MsgBox ("No Records Found")
  Else
      wb.SaveAs Filename:="Technicians - Batch Record Report" &amp; Format(Date, 
  "ddmmyyyy"), _
            FileFormat:=xlOpenXMLWorkbook, CreateBackup:=False
  End If
  End Sub
  </code></pre>