[xsl] Resending loop creation in a table.

Subject: [xsl] Resending loop creation in a table.
From: "Praveen G" <praveeng@xxxxxxxxxxxx>
Date: Wed, 26 Sep 2001 16:19:06 +0800
hi all ,
i have an xml document  with  elements like this-
<subsystem_id>value1</subsystem_id>.

<subsystem_id> value2</subsystem_id>.


<subsystem_id> value3</subsystem_id>.    etc .
now i have to design a table like the one shown BELOW..  we have total of 16
columns and 4 rows. the values indicated in the table(value 1/2/3 etc) are
the values of <subsystem_id>.
Now there can be a maximum of 64 .<subsystem_id> values and minimum can be
0ne or two ....upto 64. i.e , it varies from document to document.
This  document has other elements also. The documents vary only in
<subsystem_id> elements. i want to prepare a generic xsl stylesheet which
will create  a
table like this every where.


Now the problem is , the values has to be put in such a way that, the 5th
value will come in  column c2 and row R1.
similarly 6th value should come in column  C2   and row  R2.  It goes down
like this till 8 th value  and again the  9th value
will come in column  c3 and row  R1. similarly 10 th value will come
incolumn C3 and row  R2.
 we donot know the no. of values that are going to bepresent. so, we cannot
place them individually specifying  the corresponding
row and column. Given , VARIABLE  no. of  <subsystem_id>.s which we donot
know
, how do i create a loop for placing them in such a pattren as told above.

                 C1          C2       C3    C4   C5    UPTO........C16
|---------------------------------------------------------------------------
R1     |  value1   value5     value9
R2     |  value2   value6
R3     |  value3
R4     |  value4


i guess u got what i am trying to convey.can anyone suggest a solution
please. I need the code for it. I have tried with position()=1 |
position()=5   code , but it is giving an error in some other part of the
program.

regards,
praveen


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread