<% Const adOpenForwardOnly = 0 Const adOpenStatic = 3 Const adLockReadOnly = 1 Const adCmdTable = 2 Const adCmdText = 1 Const adUseClient = 3 Dim iPageSize 'How big our pages are Dim iPageCount 'The number of pages we get back Dim iPageCurrent 'The page we want to show Dim strOrderBy 'A fake parameter used to illustrate passing them Dim strSQL 'SQL command to execute Dim objPagingConn 'The ADODB connection object Dim listingprv 'The ADODB recordset object Dim iRecordsShown 'Loop controller for displaying just iPageSize records Dim I 'Standard looping var Dim IRecordCount strOrderBy= Request.QueryString("strOrderBy") Select CASE strOrderBy Case "Date desc", "Order", "Category", "Type" Case Else strOrderBy = "Date Desc" End Select ' Get parameters iPageSize = 15 ' You could easily allow users to change this ' Retrieve page to show or default to 1 If Request.QueryString("page") = "" Then iPageCurrent = 1 Else iPageCurrent = CInt(Request.QueryString("page")) End If strSQL = "SELECT image,eurl,iurl,headline,id,date,subheadline,info FROM press where active like true and veteran like true order by date desc,headline;" Dim objRSP Set objRSP = Server.CreateObject ("ADODB.Recordset") objRSP.Open strSQL, connStr, adOpenStatic, adLockReadOnly, adCmdText objRSp.PageSize = iPageSize ' You can change other settings as with any RS 'listingprv.CursorLocation = adUseClient objRSp.CacheSize = iPageSize ' Get the count of the pages using the given page size iPageCount = objRSp.PageCount iRecordCount = objRSp.RecordCount ' If the request page falls outside the acceptable range, ' give them the closest match (1 or max) If iPageCurrent > iPageCount Then iPageCurrent = iPageCount If iPageCurrent < 1 Then iPageCurrent = 1 ' Check page count to prevent bombing when zero results are returned! If iRecordCount = 0 Then Response.Write "

No records found! Add New Listing

" Else ' Move to the selected page objRSp.AbsolutePage = iPageCurrent %> Pickens County Georgia Veterans News - Army - Navy - Marines - Air Force - Army Air Force - Coast Guard - Merchant Marine
Pickens County Georgia Veterans
Pickens County VeteransAir ForceArmyCoast GuardMarinesMerchant MarineNavyVeterans
Veteran DirectoryVeteran Listing in Pickens CountyPickens County Veteran News & EventsPickens County Veteran Event PhotosVeteran Information Branch MilitaryPickens veteran ga
Pickens County Veterans