<% Dim strNewsId strNewsId = request.QueryString("NewsId") DIM objConn SET objConn = server.CreateObject("ADODB.Connection") objConn.mode=3 'objConn.Open strConnString objConn.Open "Driver={Microsoft Access Driver (*.mdb)};" & _ "Dbq=" & Server.MapPath(".") & "..\..\db\CalsoftGroup.mdb;" & _ "Uid=;" & _ "Pwd=;" dim rsDate,sqlDate set rsDate = Server.CreateObject("ADODB.RecordSet") sqlDate = "select distinct YEAR(publishedDate) as YearPart from News order by YEAR(publishedDate) desc" if rsDate.state =1 then rsDate.close rsDate.open sqlDate,objConn,adOpenKeySet, adLockOptimistic %>

Press Releases

<% While Not rsDate.EOF dim rsNews,sqlNews set rsNews = Server.CreateObject("ADODB.RecordSet") sqlNews = "select * from News where published='Y' and NewsId in (select distinct NewsId from NewsMap where GroupId= 3 ) and YEAR(publishedDate)="&rsDate("YearPart")&" order by publishedDate desc" if rsNews.state =1 then rsNews.close rsNews.open sqlNews,objConn,adOpenKeySet, adLockOptimistic %>

<%response.Write(rsDate("YearPart"))%>


<%while NOT rsNews.EOF%>
  • <% if rsNews("PublshedPlaceId") <>"" and rsNews("PublshedPlaceId") <>0 then dim rsPublishedPlace,sqlPublishedPlace set rsPublishedPlace = Server.CreateObject("ADODB.RecordSet") sqlPublishedPlace = "select * from PublishedPlace where PublishedPlaceId=" & rsNews("PublshedPlaceId") if rsPublishedPlace.state =1 then rsPublishedPlace.close rsPublishedPlace.open sqlPublishedPlace,objConn,adOpenKeySet, adLockOptimistic response.Write(rsPublishedPlace("PublishedPlaceName") & "
    " ) end if response.Write( monthname(month(rsNews("PublishedDate"))) &" " & day(rsNews("PublishedDate")) & " " & year(rsNews("PublishedDate"))) %>

<% rsNews.movenext wend %> <% rsDate.movenext wend %>

top

<% if objConn.state = 1 then objConn.close set objConn = nothing end if %>