On Tuesday 06 January 2004 16:50, Hari_s wrote: > I mean it's split table into separate page, > i have 100 data and i want display 10 data every pages...
Ok, kool. I had a similar thing that I wanted to do. I wanted to be able to determine odd or event numbered rows in a table so I could alternate the background colour like old fashioned printouts. I decided to do it as custom tags. Look up your J2EE tutorials for creating these. http://java.sun.com/j2ee/1.4/docs/tutorial/doc/ I ended up with 4 custom tags: <counterReset> - creates the counter variable in the page context set to 0. <counterIncrement> - adds 1 to the variable. <counterNumber> - outputs the current value. <counterEvenOrOdd> - Outputs the strings "Odd" or "Even" Each tag has 1 required parameter called "var" which is the name of the variable in the page context to be used. By specifying a variable name (same as other struts tags do) I was able to run more than one counter when necessary. Writing these tags was simplicity itself once I got the hang of it. If you go this way you will find you can do all sorts of wizzo things with them. For example: <mytags:counterReset var="counter" /> <c:forEach ....> <mytags:counterIncrement var="counter" /> <c:if test="${counter == 10}"> ... </c:if> </c:forEach> If you do this you can just add </table><table> tags inside the if statements to achieve the break up of your data. I used the odd or event tag inside class values on table cells so that the CSS classes Odd or Even where applied to the cells. -- Regards, Derek Clarkson .O. Analyst/Programmer ..O Waterwerks Pty Ltd OOO Melbourne, Australia --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]