Ok getting further but a bit stuck.
I have a new field in the repeating item node now called iCostCentreAccount and I am trying to set this with a rule on the data entry form.
If I use the following rule
xdXDocument:GetDOM("Cost Centres")/dfs:myFields/dfs:dataFields/d:Cost_Centres/@CCen_Account[../@CCenID = current()/my:aCostCentre]I get nothing in the query view. but if I use:
xdXDocument:GetDOM("Cost Centres")/dfs:myFields/dfs:dataFields/d:Cost_Centres/@CCen_Account[../@CCenID = xdXDocument:get-DOM()/my:purchaseOrder/my:items/my:item/my:aCostCentre]which is why I thought I needed current()/my:aCostCentre in there like you do for the cascading DDL's but obviously still to new to this to get the hang of the XPaths.
Anyone suggest where I should put the current() in the second formula?