|
<%
if intThisYear <> YearOfLastEvent AND YearOfLastEvent <> "" then
Response.Write intThisYear & " - " & YearOfLastEvent
else
Response.Write intThisYear
end if
%>
Events |
|
| Event |
Location |
<%
' Set the PageSize, CacheSize, and populate the intPageCount and
' intRecordCount variables.
Rs_Events.PageSize = NumRecsPerPage
' The cachesize property sets the number of records that will be cached
' locally in memory.
Rs_Events.CacheSize = Rs_Events.PageSize
intPageCount = Rs_Events.PageCount
intRecordCount = Rs_Events.RecordCount
' Now you must double check to make sure that you are not before the start
' or beyond end of the recordset. If you are beyond the end, set
' the current page equal to the last page of the recordset. If you are
' before the start, set the current page equal to the start of the recordset.
If CInt(intPage) > CInt(intPageCount) Then intPage = intPageCount
If CInt(intPage) <= 0 Then intPage = 1
' Make sure that the recordset is not empty. If it is not, then set the
' AbsolutePage property and populate the intStart and the intFinish variables.
If intRecordCount > 0 Then
Rs_Events.AbsolutePage = intPage
intStart = Rs_Events.AbsolutePosition
If CInt(intPage) = CInt(intPageCount) Then
intFinish = intRecordCount
Else
intFinish = intStart + (Rs_Events.PageSize - 1)
End if
End If
' Loop through the list.
If intRecordCount > 0 Then
For intRecord = 1 to Rs_Events.PageSize
'do until Rs_Events.EOF
%>
<%
if BackGroundColor = TableRowColor1 then
BackGroundColor = TableRowColor2
else
BackGroundColor = TableRowColor1
end if
%>
<%
vchItemThumbnail = Rs_Events("vchItemThumbnail")
if (vchItemThumbnail = "") or (isnull(vchItemThumbnail)) then
%>
<%
else
%>
" BORDER="0" WIDTH="108" HEIGHT="78" NAME="EventPic" USEMAP="#Eventmap<%=intRecord%>Map">
<%
end if
%>
|
<%
response.Write GetMonthFromNumber(Month(Rs_Events("dtStart")))
Response.Write " "
if day(Rs_Events("dtStart")) < 10 then
Response.Write "0" & day(Rs_Events("dtStart"))
else
Response.Write day(Rs_Events("dtStart"))
end if
Response.Write ", "
Response.Write Year(Rs_Events("dtStart"))
%>
<%if Rs_Events("dtStart") <> Rs_Events("dtEnd") then%>
-
<%
response.Write GetMonthFromNumber(Month(Rs_Events("dtEnd")))
Response.Write " "
if day(Rs_Events("dtEnd")) < 10 then
Response.Write "0" & day(Rs_Events("dtEnd"))
else
Response.Write day(Rs_Events("dtEnd"))
end if
Response.Write ", "
Response.Write Year(Rs_Events("dtEnd"))
%>
<%end if%>
<%
dtStartTime.CTimeToAMPM(Rs_Events("dtStartTime"))
dtEndTime.CTimeToAMPM(Rs_Events("dtEndTime"))
if datediff("n",dtStartTime.MyTime,dtEndTime.MyTime) > -1 then
if dtStartTime.MyHour < 10 then
Response.Write "" & dtStartTime.MyHour
else
Response.Write dtStartTime.MyHour
end if
Response.Write ":"
if dtStartTime.MyMinutes < 10 then
Response.Write dtStartTime.MyMinutes
else
Response.Write dtStartTime.MyMinutes
end if
Response.Write " " & dtStartTime.AMPM
%>
<%if Rs_Events("dtStartTime") <> Rs_Events("dtEndTime") then%>
-
<%
if dtEndTime.MyHour < 10 then
Response.Write "" & dtEndTime.MyHour
else
Response.Write dtEndTime.MyHour
end if
Response.Write ":"
if dtEndTime.MyMinutes < 10 then
Response.Write dtEndTime.MyMinutes
else
Response.Write dtEndTime.MyMinutes
end if
Response.Write " " & dtEndTime.AMPM
%>
<%end if%>
<%end if%>
"><%=replace(Rs_Events("vchEventName"), "''","'")%>
<%=replace(Rs_Events("vchShortEventDescription"), "''","'")%> |
<%=Rs_Events("vchLocation")%> |
|
<%
' Move to the next row
Rs_Events.MoveNext
If Rs_Events.EOF Then Exit for
' Loop back
'Loop
Next
end if 'this is the end of the intRecordCount > 0
%>
<%
' Check to see if the current page is greater than the first page
' in the recordset. If it is, then add a "Previous" link.
If cInt(intPage) > 1 Then
%>
<< Prev
<%End IF%>
<%
' You can also show page numbers:
For I = 1 To intPageCount
If I = cInt(intPage) Then
%>
<%= I %>
<%
Else
%>
<%= I %>
<%
End If
Next
%>
<%
' Check to see if the current page is less than the last page
' in the recordset. If it is, then add a "Next" link.
If cInt(intPage) < cInt(intPageCount) Then
%>
Next >>
<%End If%>
Page <%=intPage%>/<%=intPageCount%>
|
|
|