limiting number of rows displayed
1 posts in topic
Flat View  Flat View

Posted By:   Patrick_Bowe
Posted On:   Friday, May 3, 2002 09:41 AM

I'm not sure if this can be done with Java or HTML. I am retrieving rows of data from a database using JDBC. When I get the resultset, there is one field that can be many lines long. I want to make sure that field only displays two lines worth of information, however the width of the field changes when the user enlarges or shrinks their browser window. Can this be done?

Re: limiting number of rows displayed

Posted By:   s_g  
Posted On:   Friday, May 3, 2002 12:46 PM

you can restrict the display content to specified amount by using substring function of java.lang.String class.

String abc = rs.getString("column4");
abc = abc.substring(0,100);

so you will always display first 100 charcters of the column4.

Hope this will help you.
About | Sitemap | Contact