I'm hoping someone can help me out with a command or batch file? 

I have alot of files with some meta information inside them.

I'm trying to read a specific lines and rename the file from some of its content.

This is an example of the content,

```
<recording>
    <file name="currentfilename.wav">
        <fixedtags>
            <tenant value="default" />
            <campaignname value="1864" />
            <agentid value="600+1+488295" />
            <sessionid value="" />
            <telephonenumber value="99999" />
            <diallednumber value="" />
            <agentrecordedoutcome value="0" />
            <telephonyoutcome value="10" />
            <committment value="0" />
            <successrating value="0" />
            <callstarttime value="43174.629577" />
            <calllength value="16762" />
            <date value="2018-03-15" />
            <sessionGUID value="" />
            <EndpointGuid value="" />
            <SessionUniqueId value="" />
            <Direction value="Outbound" />
        </fixedtags>
        <customtags>
            <tagone value="" />
            <tagtwo value="" />
            <tagthree value="" />
            <tagfour value="" />
            <tagfive value="" />
            <tagsix value="" />
        </customtags>
        <hash></hash>
    </file>
</recording>

```

This is the output in trying to put together

Example, each name in the file is from the content within the file.

```
campaignname-telephonenumber-date-callstarttime-agentid-Direction.txt

```

so the output would look something like this

```
1864-99999-20180315-43174.629577-600+1+488295-Outbound.txt

```

Thanks,
Stewart