<% Response.Expires = 0 Response.Buffer = TRUE Response.Clear Set ObjConn = Server.CreateObject("ADODB.Connection") Set areas = Server.CreateObject("ADODB.RecordSet") dsn="DRIVER={Microsoft Access Driver (*.mdb)}; " dsn = dsn & "DBQ=" & Server.Mappath("\data\adcards.mdb") objConn.Open dsn 'ObjConn.Open "adcards" ' variables good for this session only ' reset the page number to 0 if this page is called session("pageNo") = 0 'Constants NUM_COLS = 2 Dim sqlString numAreas = 0 %> Ad Search <% sqlString = "SELECT * from Areas ORDER BY Areas.AreaDescription;" set areas = objConn.Execute(sqlString) if not(areas.eof) then numAreas = areas.RecordCount end if %>
[Real Estate Maui Style] Ad Search

Select specific areas to search or leave blank to search through all Advertisers. When you're done, press Submit:

<% ' display the areas colPos = 0 do while not areas.eof colPos = colPos + 1 if (colPos = 1) then response.write "" end if response.write "" if (colPos = NUM_COLS) then response.write "" colPos = 0 end if areas.movenext loop 'do while not areas.eof ' if we ended the table mid-col, then close off the row. It's OK if it doesn't contain ' the same amount of cells as the NUM_COL if (colPos <> 1) then response.write "" end if %>
" & areas.Fields("AreaDescription") & "


 

 

 

 

Hit Counter