首页 > 慧问 > 频道

请问如何在书签位置插入word内容?[Aspose.Words for .NET]

发表于2019-05-10 回复:0 查看:1591  |  
public void InsertFile(string vfilename, string strBookmarkName { Aspose.Words.Document srcDoc = new Aspose.Words.Document(vfilename); Aspose.Words.Bookmark bookmark = oDoc.Range.Bookmarks[strBookmarkName]; InsertDocument(bookmark.BookmarkStart.ParentNode, srcDoc); } CompositeNode dstStory = insertAfterNode.ParentNode; // This object will be translating styles and lists during the import. NodeImporter importer = new NodeImporter(srcDoc, insertAfterNode.Document, ImportFormatMode.KeepSourceFormatting); // Loop through all sections in the source document. foreach (Aspose.Words.Section srcSection in srcDoc.Sections) { // Loop through all block level nodes (paragraphs and tables) in the body of the section. foreach (Node srcNode in srcSection.Body) { // Let's skip the node if it is a last empty paragraph in
0个回答

打破零回复...

回复

登录 慧都网发表评论

扫码咨询


添加微信 立即咨询

电话咨询

客服热线
023-68661681

TOP