count occurrence of string in xpath attribute

TeMoTaikiff

New Member
Is it possible to select the nodes that has say "n" number of re occurrences of a string / character sequence in the value of the attribute of nodes?EG:\[code\]<IOCFG xmlns="http://www.br-automation.com/AR/IO" Version="2.0"><Module ID="$root.IO" Hardware="X20CP1484"></Module><Module ID="$rot.IO" Hardware="X20CP1484"></Module><Module ID="$rt.IO" Hardware="X20CP1484"></Module>**<Module ID="IF3.IF1.ST9" Hardware="Hello"/>**<Module ID="IF3.IF2.IF3.ST9" Hardware="Bye"/>**<Module ID="IF3.IF2.ST1" Hardware="hai"/>**</IOCFG>\[/code\]So from the above file I could only select the nodes with ID (attribute) which has 'IF' string occurring twice.
 
Back
Top