0
我想一些額外的行添加到表中FOP,以填補他們多達13行使用此代碼:循環在FOP失敗
<!-- Fill Up Empty space -->
<c:forEach var="i" begin="${position_id}" end="13" step="1">
<fo:table-row height="4.4mm" border-bottom-color="black"
border-bottom-style="fixed" border-bottom-width="0.2mm">
<fo:table-cell border-bottom-style="solid"
border-bottom-width="0.2mm" border-top-style="solid"
border-top-width="0.1mm">
<fo:block font-size="8pt" text-align="center">
</fo:block>
</fo:table-cell>
<fo:table-cell border-bottom-style="solid"
border-bottom-width="0.2mm" border-top-style="solid"
border-top-width="0.1mm">
<fo:block />
</fo:table-cell>
<fo:table-cell border-bottom-style="solid"
border-bottom-width="0.2mm" border-top-style="solid"
border-top-width="0.1mm">
<fo:block />
</fo:table-cell>
<fo:table-cell border-bottom-style="solid"
border-bottom-width="0.2mm" border-top-style="solid"
border-top-width="0.1mm">
<fo:block />
</fo:table-cell>
<fo:table-cell border-bottom-style="solid"
border-bottom-width="0.2mm" border-top-style="solid"
border-top-width="0.1mm">
<fo:block />
</fo:table-cell>
</fo:table-row>
</c:forEach>
問題是,我不斷收到一個例外:
org.apache.fop.fo.ValidationException: file:/tmp/fop_1613051806105460695.fo:289:126: Error(289/126): fo:table-row is not a valid child element of forEach.
at org.apache.fop.fo.FONode.invalidChildError(FONode.java:435)
at org.apache.fop.fo.FONode.invalidChildError(FONode.java:420)
at org.apache.fop.fo.XMLObj.validateChildNode(XMLObj.java:70)
...
谷歌搜索也沒有幫助。有任何想法嗎?
那麼c:forEach就是JSTL Core forEach,因爲我可以使用c:set,我不知道爲什麼這不起作用。 至於零高度,我會嘗試一個,但我的印象是,通過設置高度,我還設置了block-progresison-dimension.minimum。 – cdecker 2010-07-01 11:11:37