我使用Word2010和DSOFramer控件在winforms应用程序中嵌入word文档,我必须进入标题编辑模式,我使用以下代码:
if (wordDocument.ActiveWindow.View.SplitSpecial != WdSpecialPane.wdPaneNone)
wordDocument.ActiveWindow.Panes[2].Close();
if (wordDocument.ActiveWindow.ActivePane.View.Type == WdViewType.wdNormalView ||
wordDocument.ActiveWindow.ActivePane.View.Type == WdViewType.wdOutlineView)
wordDocument.ActiveWindow.ActivePane.View.Type = WdViewType.wdPrintView;
wordDocument.ActiveWindow.ActivePane.View.SeekView = WdSeekView.wdSeekCurrentPageHeader;但应用程序在执行以下代码行时变得无响应:
wordDocument.ActiveWindow.ActivePane.View.SeekView = WdSeekView.wdSeekCurrentPageHeader;
诚挚的问候。
发布于 2011-07-15 17:15:12
可以在这里找到解决方案Word 2010 header edition
https://stackoverflow.com/questions/6681030
复制相似问题