In MS Words, to make the columns in a table automatically fit the contents, we click on the table. On the Layout tab, in the Cell Size group, click AutoFit, and then click AutoFit Contents.
After applying AutoFit to Content, here's the result :
I am using Microsoft Open XML SDK to implement above feature. I have created a method to group my table cells by columns and then I set each column width to the largest cell content length.
But the issue is, some cells are either merged horizontally or vertically (That's where lays my main issue), making my solution an absolute fiasco. I searched everywhere, but I did not find some helpful resources
After an extensive search spanning several days, I have exhausted my efforts and decided to seek assistance by posing my question on this forum. Having familiarized myself with the forum's guidelines on asking questions, I am now presenting my query and kindly requesting suggestions for a solution.