on 2011 Mar 18 9:53 AM
Hello,
I want to empty a node in the controller, I tried several attempts to do so, but no attempt is good.
I would like to know if someone already met this problem? If yes, please give me the solution.
Hi,
If your node is a value node then invalidate() will work.
If your node is a model node then for clearing the node, you have the create object of particular model class and bind it to the context node Or remove elements from the model node.
Regards,
Amol
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi...
U can try
wdContext.node<node name>.reset()
node will lose its data...
jaya
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
The invalidate() method for node should work to clear the nodes element collection.
else we can set "" to each context attribute in a node.
If your node cardinality is 1..1
wdcontext.current<nodeelement>().setname("");
if your node cardinality is 0..n
for (int i=0;i<wdcontext.node<nodename>().size();i++)
{
wdContext.node<nodename>().get<node>ElementAt(i).setname("");
}
Regards,
Bala Baskaran.S
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
To empty the nodes element collection, you can use the code
wdContext.node<nodename>().invalidate();
Regards,
Bala Baskaran.S
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
70 | |
10 | |
10 | |
7 | |
6 | |
6 | |
6 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.