小编Blu*_*oth的帖子

Adding multiple images to a word document at a specific locations OpenXML

I am using Office Open XML and I have to add images at a specific points. On the document I have a \'tag\' so I can locate it just fine. However, when I add more than one image, it corrupts the file.

\n\n

在此输入图像描述

\n\n

Here\'s my code: (Modified from https://msdn.microsoft.com/en-us/library/office/bb497430.aspx)

\n\n

Using:

\n\n
using DocumentFormat.OpenXml.Wordprocessing;\nusing A = DocumentFormat.OpenXml.Drawing;\nusing DW = DocumentFormat.OpenXml.Drawing.Wordprocessing;\nusing PIC = DocumentFormat.OpenXml.Drawing.Pictures;\n
Run Code Online (Sandbox Code Playgroud)\n\n

My Main:

\n\n
private const string Loc = @"D:\\Documents\\2-Mass Output.docx";\nstatic void Main(string[] args)\n{\n    var …
Run Code Online (Sandbox Code Playgroud)

c# openxml

6
推荐指数
1
解决办法
4447
查看次数

标签 统计

c# ×1

openxml ×1