如何判断 XmlMap 指向何处(哪些单元格)?

发布于 2024-10-01 13:25:55 字数 96 浏览 0 评论 0原文

我需要获取 Excel 工作表中特定 XmlMap 通过互操作以编程方式指向的范围(行、列等)。有人有什么想法吗?我看不到提供此信息的 XmlMap 接口的任何属性/方法/成员。

I need to grab the ranges (row, column etc.) a particular XmlMap in an excel worksheet is pointing to programmatically via interop. Does anyone have any thoughts? I can not see any properties/methods/members of the XmlMap interface that provide this information.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

清风无影 2024-10-08 13:25:55

我最终通过将 XmlMap 输出转储到文件、使用 .NET XML 库查找映射中的所有元素并使用“Worksheet.XmlDataQuery”查找每个元素的单元格/范围位置来解决此问题。它很脏,但这是我让它发挥作用的唯一方法。

I ended up solving this problem by dumping the XmlMap output to a file, using the .NET XML library to find all of the elements in the map and the using 'Worksheet.XmlDataQuery' to find to cell/range location of each element. Its dirty, but its the only way I could get this to work.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文