Newsletter

<% Set rs = Server.CreateObject("ADODB.Recordset") rs.CursorType = 3 rs.CursorLocation = 3 SQL = "Select Top 1 * From tbl_Newsletter Where Archive = False Order By NewsDated Desc" rs.open SQL, conn if (rs.Recordcount > 0 )then %> <% counter = 1 while not rs.EOF UpFile = trim(rs("UpFile")) %> <% rs.MoveNext counter = counter + 1 wend %>
•  <%= trim(rs("Title"))%>
<% else%>
There are no records at present
<% end if %>

Archived Newsletter

    
<% 'if (Request.Form("drpYear")="Submit") then if (Request.QueryString("Year")<>"") then YearN = Request.QueryString("Year") else YearN = Year(Date) end if Set rsL = Server.CreateObject("ADODB.Recordset") rsL.CursorType = 3 rsL.CursorLocation = 3 SQLL = "Select * From tbl_Newsletter Where Year(NewsDated) = '"& YearN &"' And Archive = true " 'Response.Write(SQLL) rsL.open SQLL, conn if (rsL.Recordcount > 0 )then %> <% counter = 1 while not rsL.EOF %> <% rsL.MoveNext counter = counter + 1 wend %>
•  " target="_blank" class="arr"><%= trim(rsL("Title"))%>
<% else %>
<% if (Request.QueryString("Year")<>"") then %>There are no records in archive for <%= YearN %><% end if%>
<% 'end if end if %>