I need to create a xml file where I have this structure:
<term name="example 1">
<customAttributes>
<customAttributeValue customAttribute="xyz">
<customAttributeReferences>
<columnRef table="a" column="x"/>
<columnRef table="b" column="x"/>
<columnRef table="c" column="x"/>
</customAttributeReferences>
</customAttributeValue>
</term>
I'm using only excel to create the file, but the only structure that I'm being able to export is this:
<term name="example 1">
<customAttributes>
<customAttributeValue customAttribute="xyz">
<customAttributeReferences>
<columnRef table="a" column="x"/>
</customAttributeReferences>
</customAttributeValue>
</term>
<term name="example 1">
<customAttributes>
<customAttributeValue customAttribute="xyz">
<customAttributeReferences>
<columnRef table="b" column="x"/>
</customAttributeReferences>
</customAttributeValue>
</term>
<term name="example 1">
<customAttributes>
<customAttributeValue customAttribute="xyz">
<customAttributeReferences>
<columnRef table="c" column="x"/>
</customAttributeReferences>
</customAttributeValue>
</term>
The table structure that I have is like this:
| terms | table | column |
| -------- | ----------| ------ |
| example 1 | a | x |
| example 1 | b | x |
| example 1 | c | x |
Can someone help me? I can use VBA if necessary. Thank you!
Try this. Quite a bit of code but most of it is utility methods - only
Tester
is specific to your task.