1. First you need to install the Add-In: 2007 Microsoft Office Add-in: Microsoft Save as PDF
2. You need to create Bookmark in msWordMicrosoft.Office.Interop.Word.Application ap = new Microsoft.Office.Interop.Word.Application();
Microsoft.Office.Interop.Word.Document doc1 = ap.Documents.Open(@"c:\test.docx", ReadOnly: false, Visible: false);
Object oBookmarkTOC1 = "BookMarkName";object format = Microsoft.Office.Interop.Word.WdSaveFormat.wdFormatPDF; //Update BookMark
doc1.Bookmarks.get_Item(ref oBookmarkTOC1).Range.Text = "Bla Bla 123";
Read more: Uzi Drori's Blog
2. You need to create Bookmark in msWordMicrosoft.Office.Interop.Word.Application ap = new Microsoft.Office.Interop.Word.Application();
Microsoft.Office.Interop.Word.Document doc1 = ap.Documents.Open(@"c:\test.docx", ReadOnly: false, Visible: false);
Object oBookmarkTOC1 = "BookMarkName";object format = Microsoft.Office.Interop.Word.WdSaveFormat.wdFormatPDF; //Update BookMark
doc1.Bookmarks.get_Item(ref oBookmarkTOC1).Range.Text = "Bla Bla 123";
Read more: Uzi Drori's Blog
0 comments:
Post a Comment