Hide Particular fielda in a table

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Hide Particular fielda in a table

Sathish K Mittapelli

Hi all,

I am trying to hide some rows in a table in UI....i have written my code like this....

<xforms:repeat nodeset="instance('selected-instance')//question" id="repeat1" if="!(instance('selected-instance')/question/status='delete')">
<xhtml:tr>
   
    <xhtml:td>
        <xforms:select ref="xxforms:repeat-current('repeat1')/selected" appearance="full">
                <xforms:item>
                      <xforms:label></xforms:label>
                      <xforms:value>true</xforms:value>
                </xforms:item>
            </xforms:select>
   
    </xhtml:td>
    <xhtml:td>
        <xforms:output ref="quest">
           
        </xforms:output>
    </xhtml:td>
   
    <xhtml:td>
        <xforms:output ref="questkey">
           
        </xforms:output>
    </xhtml:td>
   
   
    <xhtml:td>
        <xforms:output ref="anstype">
           
        </xforms:output>
    </xhtml:td>
   
</xhtml:tr>
</xforms:repeat>..

.......


I have written a trigger which is like this

<xforms:trigger>
        <xforms:label>Remove</xforms:label>
        <!-- xforms:delete ev:event="DOMActivate"  nodeset="instance('selected-instance')//question" at="index('repeat1')"/ -->
        <xforms:action ev:event="DOMActivate" xxforms:iterate="instance('selected-instance')/question[selected='true']">
                <xforms:setvalue ref="instance('selected-instance')/question[selected='true']/status" value="delete"/>
        </xforms:action>       
        </xforms:trigger>

When i am trying to setvalue it is not setting value 'delete '
for status.

Please help me how to achieve this....
THANKS & REGARDS
SATHISH K MITTAPELLI  


Best Jokes, Best Friends, Best Food. Get all this and more on Best of Yahoo! Groups.

--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Hide Particular fielda in a table

Alessandro Vernet
Administrator
On Mon, May 26, 2008 at 3:51 AM, sathish kumar <[hidden email]> wrote:
> <xforms:repeat nodeset="instance('selected-instance')//question"
> id="repeat1" if="!(instance('selected-instance')/question/status='delete')">

You can't use the "if" attribute on xforms:repeat. The "if" attribute
only applies to actions. Instead you would have to use a predicate:
instance('selected-instance')//question[condition].

Alex
--
Orbeon Forms - Web 2.0 Forms, open-source, for the Enterprise
Orbeon's Blog: http://www.orbeon.com/blog/
Personal Blog: http://avernet.blogspot.com/
Twitter - http://twitter.com/avernet


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws