When using the OpenXML SDK to apply a border to a merged cell range, the border is only showing up for the first (top left) cell in the merge range. I have absolutely no idea and this is driving me crazy. Using the productivity tool I can't find any meaningful difference in what I have and something that works as expected. This is my generated XML for the stylesheet:
<x:borders count="2" xmlns:x="http://schemas.openxmlformats.org/spreadsheetml/2006/main">
<x:border>
<x:left />
<x:right />
<x:top />
<x:bottom />
<x:diagonal />
</x:border>
<x:border>
<x:left />
<x:right />
<x:top />
<x:bottom style="thick">
<x:color auto="1" />
</x:bottom>
<x:diagonal />
</x:border>
</x:borders>
<x:cellXfs xmlns:x="http://schemas.openxmlformats.org/spreadsheetml/2006/main">
<x:xf fontId="0" />
<x:xf fontId="1" fillId="2" applyFont="1" applyFill="1" />
<x:xf borderId="1" applyBorder="1" />
</x:cellXfs>
I've tried everything, applying the merge before the border, after, etc.