Renaming xml files using file contents and RegEx

Advanced Renamer forum
#1 : 08/11-22 09:52
Barry Caldwell
Barry Caldwell
Posts: 1

I'm trying to work out how to add an xml key value from the contents of the file to the file itself.
The file has variable length contents so I can't use a predictable start position or length.

How can I read the contents of the file into a string so I can use regular repressions with a capture group to extract the value I'm looking for?
Is the JS implementation in AdvancedRenamer capable of this?

Many thanks, Barry.

08/11-22 09:52
#2 : 08/11-22 15:50
David Lee
David Lee
Posts: 1026
Reply to #1:
Check out the <File Content> & <File Line> tags (Advanced Tags). You can use tags in a script using app.parseTags().

Note that the <File Line> tag was introduced in Version 3.61 (14. jan. 2014) but is not mentioned in the User Guide - however see the What's New page for details:

08/11-22 15:50