title: Find Last Chosen Day of a Chosen Month
body: <p>I have this code which allows me to find the first or last given day of the given month.</p>
  
  <p>=DATE(B2,A2,1+7*n)-WEEKDAY(DATE(B2,A2,8-xday))</p>
  
  <ul>
  <li>B2 = Year</li>
  <li>A2 = Month</li>
  <li>n = do I the want to find the 1st, 2nd, 3rd, 4th, or 5th occurrence</li>
  <li>xday = is a number representing the day of the week (1 = Sun through to 7 = Sat)</li>
  </ul>
  
  <p>I want something which will find only the last given day of the given month without me having to figure out whether the month has 4 or 5 Mondays. </p>
  
  <p>If someone can show me how to create the result I want in VBA that would be perfect.</p>