Hi,

I want management the visibility of some sections in a odt document .
In jopendocument library I only find showParagraph and hideParagraph
methods in org.jopendocument.dom.template.JavaScriptFileTemplate
class .

I extend this class with the following methods :

    public void showTable(String name) {
        this.setField("showTable_" + name, Boolean.TRUE);
    }
    public void hideTable(String name) {
        this.setField("showTable_" + name, Boolean.FALSE);
    }

    public void showSection(String name) {
        this.setField("showSection_" + name, Boolean.TRUE);
    }
    public void hideSection(String name) {
        this.setField("showSection_" + name, Boolean.FALSE);
    }

    public void showListItem(String name) {
        this.setField("showListItem_" + name, Boolean.TRUE);
    }
    public void hideListItem(String name) {
        this.setField("showListItem_" + name, Boolean.FALSE);
    }

but for section element the methods don't work and I have the
following error :

Couldn't prepare <text:script
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0"
xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0"
script:language="JODScript">&lt;if test="showSection_SECTION"
element="section"/&gt;</text:script>

Could you help me please ?
Thank a lots . Best regards. Sorry for my little english .

Reply via email to