我需要使用 openxml sdk 过滤表列的内容(在 MS-word 文档中)。我可以使用获取表格列内容(作为字符串) reference = tablerow.ElementAt<OpenXmlElement>(0).InnerText
我需要做的是将列的内容拆分为多个字符串,例如:列
abcd
efgh
我正在abcdefgh
参考使用reference = tablerow.ElementAt<OpenXmlElement>(0).InnerText
我需要的是拆分abcd
成efgh
不同的字符串。
这是我正在使用的一段代码:
foreach (Table table in tables)
{
foreach (TableRow tablerow in table.Descendants<TableRow>())
{
reference = tablerow.ElementAt<OpenXmlElement>(0).InnerText
}
}