User manual
//Outputing the Data in a table
while (more)
{
//If statement to change the background color of the
table
if (color)
{
out.println("<TR bgcolor=\"#0099CC\">");
if ( rs.getString("Contactname") == null )
out.println("<TD> </TD>");
else
out.println("<TD>" +
rs.getString("Contactname") + "</TD>");
if ( rs.getString("Phone1") == null )
out.println("<TD> </TD>");
else
out.println("<TD>" +
rs.getString("Phone1") + "</TD>");
if ( rs.getString("Phone2") == null )
out.println("<TD> </TD>");
else
out.println("<TD>" +
rs.getString("Phone2") + "</TD>");
if ( rs.getString("Phone3") == null )
out.println("<TD> </TD>");
else
out.println("<TD>" +
rs.getString("Phone3") + "</TD>");
if ( rs.getString("Phone4") == null )
out.println("<TD> </TD>");
else
out.println("<TD>" +
rs.getString("Phone4") + "</TD>");
if ( rs.getString("Phone5") == null )
out.println("<TD> </TD>");
else
out.println("<TD>" +
rs.getString("Phone5") + "</TD>");
if ( rs.getString("Phone6") == null )
out.println("<TD> </TD>");
else
out.println("<TD>" +
rs.getString("Phone6") + "</TD>");
out.println("</TR>");
//using rs.next to get the next value
more = rs.next();
color =false;
}
else
{
//Code to change background color of the
table
52