1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58
| using DocumentFormat.OpenXml.Wordprocessing;
using DocumentFormat.OpenXml;
using wp = DocumentFormat.OpenXml.Drawing.Wordprocessing;
using a = DocumentFormat.OpenXml.Drawing;
using pic = DocumentFormat.OpenXml.Drawing.Pictures;
namespace GeneratedCode
{
public class GeneratedClass
{
public static Document GenerateDocument()
{
var element =
new Document(
new Body(
new Paragraph(
new Run(
new RunProperties(
new NoProof(),
new Languages(){ EastAsia = "fr-FR" }),
new Drawing(
new wp.Inline(
new wp.Extent(){ Cx = 2038350L, Cy = 3238500L },
new wp.EffectExtent(){ LeftEdge = 19050L, TopEdge = 0L, RightEdge = 0L, BottomEdge = 0L },
new wp.DocProperties(){ Id = (UInt32Value)1U, Name = "Image 0", Description = "bb409621_structureOpenXML_fig01(fr-fr).jpg" },
new wp.NonVisualGraphicFrameDrawingProperties(
new a.GraphicFrameLocks(){ NoChangeAspect = true }),
new a.Graphic(
new a.GraphicData(
new pic.Picture(
new pic.NonVisualPictureProperties(
new pic.NonVisualDrawingProperties(){ Id = (UInt32Value)0U, Name = "bb409621_structureOpenXML_fig01(fr-fr).jpg" },
new pic.NonVisualPictureDrawingProperties()),
new pic.BlipFill(
new a.Blip(){ Embed = "rId4", CompressionState = a.BlipCompressionValues.Print },
new a.Stretch(
new a.FillRectangle())),
new pic.ShapeProperties(
new a.Transform2D(
new a.Offset(){ X = 0L, Y = 0L },
new a.Extents(){ Cx = 2038350L, Cy = 3238500L }),
new a.PresetGeometry(
new a.AdjustValueList()
){ Preset = a.ShapeTypeValues.Rectangle }))
){ Uri = "http://schemas.openxmlformats.org/drawingml/2006/picture" })
){ DistanceFromTop = (UInt32Value)0U, DistanceFromBottom = (UInt32Value)0U, DistanceFromLeft = (UInt32Value)0U, DistanceFromRight = (UInt32Value)0U }))
){ RsidParagraphAddition = new HexBinaryValue() { Value = "00AE0910"}, RsidRunAdditionDefault = new HexBinaryValue() { Value = "005D1B73"} },
new SectionProperties(
new PageSize(){ Width = (UInt32Value)11906U, Height = (UInt32Value)16838U },
new PageMargin(){ Top = 1417, Right = (UInt32Value)1417U, Bottom = 1417, Left = (UInt32Value)1417U, Header = (UInt32Value)708U, Footer = (UInt32Value)708U, Gutter = (UInt32Value)0U },
new Columns(){ Space = (UInt32Value)708U },
new DocGrid(){ LinePitch = 360 }
){ RsidR = new HexBinaryValue() { Value = "00AE0910"}, RsidSect = new HexBinaryValue() { Value = "00AE0910"} }));
return element;
}
}
} |
Partager