<% @LANGUAGE="VBScript" %> <% Option Explicit %> <% 'create variables Dim SQL Dim strDate 'Set variable to todays date strDate = Date 'Call our database connection from include file Call OpenDB() 'Create SQL query SQL = "Select EventID, DayOfWeek, EventName, EventDate, Reviewed FROM Events ORDER BY EventDate, EventName, EventID;" 'Open recordset and execute query Set RS = dbConn.Execute(SQL) %> MAX Events

Activities: Event List    



 

 
Reserve space for yourself and guests at these MAX events!

<% 'Start our loop through the database DO UNTIL RS.EOF 'Check to see if the event has been reviewed for publishing. 'Also, if it is older than today we do not show it IF UCase(RS("Reviewed")) = "Y" AND RS("EventDate") >= strDate Then 'Some code to alternate row color Dim x, bgcolor if x = 1 then bgcolor="#E9E9E9" x=2 Else bgcolor="White" x=1 End if Dim theMonthName, theMonthNameAbbr, theDay 'Get month number theMonthName = Month(RS("EventDate")) 'Convert month number to month name - True means abbreviated month name theMonthName = MonthName(theMonthName) 'Get the Day theDay = Day(RS("EventDate")) %> <% End IF RS.MoveNext Loop %>
 DAY
 DATE
 EVENT
<%=RS("DayOfWeek")%>  <%=theMonthName%> <%=theDay%> "><%=RS("EventName")%>
 


Looking for a past event? Click here to view all MAX events.

<% 'Close and destroy connections Set RS = Nothing Call CloseDB() %>