'While days are greater than count Do While count < varDays 'Increase Count count = count + 1 'Check details of today rtnEventPage = "" sql = "SELECT id, datedisplay, container FROM cms WHERE container=7 AND datedisplay = "&DateSerial( 2006, 7, count ) set rtnEventPage = connection.execute(sql) varDetail = 0 If rtnEventPage.EOF = true Then varDetail = 2 End If If count = Day(Now()) Then varDetail = 1 End If 'Print type Select Case varDetail 'Event day Case 2 varCalendar = varCalendar + "