需要知道文件格式,才能将PDF嵌入OpenXML中的DOC

时间:2019-05-21 11:00:22

标签: c# openxml openxml-sdk openxml-table

我正在使用OpenXML生成DOC。我已经将PDF嵌入到段落中。当我使用由OpenXML外部工具生成的partdata时,它正在工作。现在,我需要转换选定的PDF文件并将其嵌入到DOC中。但是我找不到需要转换的格式。

转换为字节,然后转换为Base64。

string val = Convert.ToBase64String(bytes, 0, bytes.Length);

没有错误,但无法打开Base64的嵌入式文件。所以我需要知道它将接受哪种格式。

图像的样本代码为
AQAAAGwAAAAAAAAAAQAAAGUAAAA7AAAAAAAAAAAAAADeEAAA7AkAACBFTUYAAAEAkBUAABEAAAACAAAAAAAAAAAAAAAAAAAAkAYAABoEAAC8AgAAkAEAAAAAAAAAAAAAAAAAAGCuCgCAGgYAGAAAAAwAAAAAAAAAGQAAAAwAAAD /// 8AcgAAAKAQAAAjAAAAAQAAAEIAAAAgAAAAIwAAAAEAAAAgAAAAIAAAAACA / wEAAAAAAAAAAAAAgD8AAAAAAAAAAAAAgD8AAAAAAAAAAP /// wAAAAAAbAAAADQAAACgAAAAABAAACAAAAAgAAAAKAAAACAAAAAgAAAAAQAgAAMAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAA / WAA / WAA / wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQIQECYv19gWIf // // FIH XYH // // 8WIf FIH // // XYH // 8WIf FIH // // XYH // 8WIf FIH // XYH // 8WIf // FiH // xYh // 8WIf // FiH // xYh // 8WIf // FiH // xok9vYFCEBAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQGMDApanu9fX19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19 / 9fX1 // X1 9f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / v8Hr8xMc4OAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABYh //// 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / 9 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / FiH // wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFiH /// X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f8WIf // AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWIf // 9fX1 // X19f / 19fX / 9fX / 9fX // X19f / 19fX / 9fX1 / ywsLP85OTn / v7 + // ywsLP / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / xYh // 8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABYh //// 19fX / 9fX1 // 19fX / 9fX1 // // X19f8sLCz / OTk5 / 6Wlpf / 19fX / LCws / 83Nzf85OTn / LCws // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / FiH // wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFiH /// X19 / 19fX / 9fX1 / ywsLP / a2tr / LCws // X19f8sLCz / 9fX1 / ywsLP8sLCz / LCws / 7Kysv / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f8WIf // AAAAAAAAAAAAAAAAXAAAfAAA1AAA9AAAAAAAAAAAAAAA X19f / 19fX / LCws / + jo6P8sLCz / 9fX1 / ywsLP / a2tr / OTk5 / ywsLP / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / xYh // 8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABYh /// 19fX / 9fX1 // X19fs / 19fX / 9ws / 4qKiv / 19fX / LCws / zk5Of + ysrL / LCws / ywsLP + Kior / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / FiH // wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFiH /// X19f / 19fX / 9fX1 / 9fX1 / // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f8WIf /// AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWIf // 9fX 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / xYh / h / 8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA贡献了感谢的朋友才能回去了/ 19fX / 9fX1 // X19f / 19fX / d337 / xYh // 8xO / 7 / r7L4 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / FiH // wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFiH /// X19f / 19fX / 9fX1 // X19f8WIf // r7L4 / 4WL + v8WIf // vcD4 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / // X19f / 19fX / 9fX1 // X19f8WIf // AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWIf // 9fX1 // X19f / 19fX / 9fX1 / 3d9 + / 9pcPv / 5 + j2 / 6Gl + f8xO / 7/5 + j2 // X19f / 19fX / 9fX1 // X19f / n6Pb / oaX5 / 4WL + v + vsvj / 9fX1 // X19f / 19fX / 9fX1 / xYh // 8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABYh //// 19fX / 9fX1 // X19f / 19fX / 9fX1 / 6 + y + P8xO / 7 / aXD7 / 1tj / P9bY / z / oaX5 / 73A + P / Z2vb / k5j5 / yMt / v9NVb3TV / z / 9fX1 // X19f / 19fX / FiH // wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFiH /// X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f + vsvj / W2P8 / yMt / v9pcPv / MTv + / xY 5 + j2 // X19f / n6Pb / TVX9 / z9I / f / 19fX / 9fX1 // X19f8WIf // AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWIf // 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19 // Z2vb / Iy3 + / z9I / f9NVf3 / MTv + / xYh // 9bY / z / y833 // X19f / 19fX / 9fX1 / xYh // 8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABYh /// 19fX / 9fX1 // X19f / 19fX / 9fX / 9fX1 // X19f + hpfn / d337 / 01V / f9pcPv / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / FiH // wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFH /// X19f / 19fX / 9fX / 9fX / 9fX1 / 9 / 19fX / 9fX1 // X19f / 19fX / 9fX1 / + fo9v8WIf // Iy3 + / + fo9v / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / vcD4 / yMt / v8xO / 7 / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / xYh // 8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABYBYh /// 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f9pcPv / vcD4 / xYh /// Lzff / 9fX1 // X19f / 19f / 19fX / 19fX / 9fX1 // X19f / 19fX / FiH // wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFiH /// X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / 01V / f / 19fX / TVX9 / 4WL + v / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / + fo9v8WIf // AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWIf // 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19FX / oaX5 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / hYnc4hAYwMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABYhh /// 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / s / X19f / 19fX / // yMt / v / n6Pb / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / 8vN9 / 8YI / X1CAxgYAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFiH /// X19f / 19fX / 9fX1 // X19f / 19fX / 9 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / Lzff / GiT29g0UoKAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAWIf // 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / AAA7AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA / Lzff / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / 8vN9 / 8aJPb2DRSgoAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEBjAwDk + rbDn6Pb / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 // X19f / 19fX / 9fX1 / + fo9v92fOvwGCP19Q0UoKAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAH / FIH // // XYH // 8WIf FIH // // XYH // 8WIf FIH // xMc4OAIDGBgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAYAAAADAAAAAAAAAISAAAADAAAAAEAAABS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