on 07-10-2008 2:48 PM
Hi Experts,
I have written the code such as
var Items = xfa.resolveNode("xfa.record.ITAB.DATA")
var leng = Items.nodes.length
but getting error Error: accessor'Items.nodes.length' is unknown
I am using FormCalc script. How we process the internal table & get length.I am struggling last three days...Please help me out...
Thanks
Not sure about your data structure, but try getting the Table's length using the following code:
The Scripting language must be set to Javascript.
var tableNodes = xfa.form.data.subformCodes.TableCodes.nodes;
var tableLength = tableNodes.length;
xfa.host.messageBox("tableLength: " + tableLength);
(you'll have to adjust the first line of code to match your structure)
hope this helps,
harman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
To be clear, I have a field called Material ID, Material Text and Material Group. Material ID and Text mapped to Dropdown. Based on selected Material ID, I need to get the Material Group.
If I give the static row like below:
$.resolveNode("$record.GT_MAT.DATA[6].MATGR", " I can able to get the value.
"But If I give in loop like below
$.resolveNode("$record.GT_MAT.DATA<i>.MATGR", "its not working.
Pls. help..
hi,
I guess you are not passing the index correctly.
$.resolveNode("$record.GT_MAT.DATA<i>.MATGR
is not correct. Instead you should give it like this.
var nodelength = "get the length of the node here..
for (i=0;i<nodelength;i++)
{
$.resolveNode("$record.GT_MAT.DATA["+ i +"].MATGR"
}
Just be sure about the i outside the "" quotes.
Cheers,
Sam
Solved
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.