I want to populate 'Office.context.document.settings' from DotNet code. Through the XML SDK I can read the settings from document.WebExTaskpanesPart.WebExtensionParts.FirstOrDefault().WebExtension.WebExtensionPropertyBag, but how do I add a 'Setting'
?
WebExtensionPropertyBag is an enumeraltion of OpenXmlElement, so I though WebExtensionPropertyBag.Append() would do it, but OpenXmlElement doesn't support 'new OpenXmlElement()'. So how do you use WebExtensionPropertyBag.Append()
?
Am trying to open an xml file from a word document and modify parts and save it back as a word doc
public partial class Form1 : Form
{
string filepath = ".snip...\\documents\\visual studio 2013\\Projects\\WindowsFormsApplication1\\WindowsFormsApplication1\\xm.xml";
WordprocessingDocument wordprocdocmnt; // = new WordprocessingDocument();
object doc1;
public Form1()
{
InitializeComponent();
try
{
wordprocdocmnt = WordprocessingDocument.Open(filepath, true);
}
catch (Exception ex)
{
MessageBox.Show("error opening document: " + ex.ToString());
}
Body body = wordprocdocmnt.MainDocumentPart.Document.Body;
}
the part in the try section fails saying system.io.fileformatexception: file contains corrupted data. at MS.internal.IO.Zip.ZipIOEndofCentralDirectoryBlock.SeekableLoad(...
I look this up and find that my xml file is not in the proper format, use the OpenXML SDK 2.5 tool? no, it says file is corrupted. this is the xml file from a word doc and i just want to treat various parts of the xml as variables to write my
own values.
so if the sdk 2.5 tool can see the xml then my code probably will too but how to get there from here?? thanks
I'm attempting to use the Open XML SDK with visual studio 2015. My goal is to create a workbook that has an externally loaded image. I've added a reference to the package I'm using (DocumentFormat.openXML), and when I'm in visual studio, there are no apparent
errors. However, when I attempt to compile or run the program, I get messages saying that I am missing a reference to DocumentFormat and all other Open XML packages. I've already added the reference, so what could I be doing wrong?
It may be worth noting that Visual Studio is installed across multiple drives but that doesn't seem like an issue.
I want to access and modify just the parts of the docx document that i setup in developer mode, the goal is to find a statement similar to using select controls by tag?
this is an example of a visual basic or VBA code snippet, Im using c# in asp.net/mvc web app; but the goal is to have a mechanism to accurately and reliably modify the fields of "text content" that i have assigned properties to, the code example
is from:
the goal is to have a method that i can pass the field name and its new string value to and save the document. there is a reference document that never changes, its always used as a base document.
my hopeful method is UpdateField, the unknown Microsoft or openXml method that would define a new control of type text is
DocumentControlItem(Text)
WordDocumentType mydocument;
public void UpdateField(document, string fieldname, string value){
myTxtcontrol DocumentControlitem = new DocumentControlItem(Text);
myTxtcontrol = document.SelectContentControlsByTag(fieldname)
}
so is there a way to open the word document and be able to access the fields this way, such as the text controls that were pre defined and saved?
Private Sub Document_ContentControlOnExit(ByVal ContentControl As ContentControl, Cancel As Boolean)
Select Case ContentControl.Tag'"Last" = tag property applied to the last control.
Case "Last"'"First" = tag property applied to the first control.
ActiveDocument.SelectContentControlsByTag("First").Item(1).Range.Select
End Select
lbl_Exit:
Exit Sub
I've been using the Word 2007 Content Control Toolkit
and I've found it a huge help. But there's one thing I'd like to know: how can someone access and work with the Parts it's created in a document if they don't have the toolkit? That is, has it created proper schemas in some place, and how do I find them?
I am trying to implement Revisions as part of a web application that I'm working on.
We have a webform to capture data. These data need to be available in MS Word doc created. However, the added text should be in revision mode so that the admin can accept or reject based on some criteria.
We are able to put the text but some it is not being captured as part of rivision. The track changes is already turned on. Please help me.
I have to render the water mark text as shape for word document to image conversion. While i am checking with remove the path and equations from document level, i can see the same watermark text in word document with that referred css style.
Is it possible to generate the graphics path based on css style alone? or able to generate vml equations manually by given css style information?
Take a look of the snapshot for css style and path equations:
Image may be NSFW. Clik here to view.Image may be NSFW. Clik here to view.
I need to to do all the rendering works with GDI+.
I'm fairly new to developing in office and I'm very new to the open office SDK. I'm attempting to use the SDK to add external relationships to an existing workbook. The reference doesn't provide any examples of how one might accomplish this. Can I add an
external relationship to the workbook itself? Or does it need to be a specific drawing/worksheet/some other object? I'm just looking for some guidance as to how the AddExternalRelationship method is used and what has to be true of the spreadsheet for it to
work without corrupting the file.
As I found, particular cell's color is there under one of above attributes. ( I referred this as well http://stackoverflow.com/questions/10756206/getting-cell-backgroundcolor-in-excel-with-open-xml-2-0
)
some cell's colors were there under
ct.RGb.Value which displayed as values with 8 hexavalues called HexaBinary and
some cell's colors were there under ct.tint.value which displayed as a decimal value between 0 and 1
etc..
How to find the exact color using them?
How to convert those colors to known colors like hexadecimal html formatted colors?
I am preparaing a word 2010 High Level Application Design Documet with standard sections and content controls.
This document will be used as a template by all the application teams and we don't them to delete the sections in the document by missing certain design elements in High level design document.
So basically we need to valdiate the document that is filled out by the application team.(For example Infrastructure Guidelines,Application Security,Architecture styles etc.).
So how can i validate a word document(basically document.xml) against a XSD for the sections in the pre-defined template provided.
I'm trying to add a picture (with an external relationship) to a document. It works fine if the document is blank, but if there are already pictures in the document, then I get the following exception:
"Only one instance of this type is allowed for this parent."
i am new to open xml. i have some requirement for my project.
i need to insert text or paragraphs in the powerpoint slide dynamically that is coming from excel sheet .
Excel is the source document which contains texts and paragraphs.
For example : sheet 1 contains the following information. i need to retrieve these informations and write it into the powerpoint presentation. if the text limit reaches the end of the slide it should automatically create a new slide.
Image may be NSFW. Clik here to view.
Currently am able to read all the contents from excel sheet and i could load in the dataset. after loading the content in the dataset i dont know how to write the loaded contents in the presentation slide.
i created an empty presentation using openxml with PresentationParts,SlidePart,SlideLayoutPart,SlideMasterPart,Theme.
My Code:
public void generate_click(object sender, EventArgs e)
{
string scode = "C:\\Users\\302480\\Documents\\Visual Studio 2010\\Projects\\ppt\\ppt\\Source\\Excel_Source_ppt\\test.pptx";
CreatePresentation(scode);
sExcelPath = Server.MapPath("~/Source/Excel_Source_ppt/") + ConfigurationManager.AppSettings["TEMS_ppt"].ToString();
sConnString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" + sExcelPath + ".xlsx;Extended Properties=Excel 12.0";
Get_WorkSheet_Names();
Get_Excel_Data();
foreach (DataTable table in dsSOW.Tables)
{
foreach (DataRow dr in table.Rows)
{
no = dr.ItemArray[0].ToString();
desc = dr.ItemArray[1].ToString();
data = no+ " " + desc;
}
}
private void Get_WorkSheet_Names()
{
string sWorkSheetsColl = String.Empty;
{
int iIndex = 0;
oConn = new OleDbConnection(sConnString);
oConn.Open();
dtList = oConn.GetSchema("Tables");
if (dtList != null)
{
dsSOW = new DataSet();
foreach (DataRow dr in dtList.Rows)
{
if (dr["TABLE_NAME"].ToString().ToLower() != "_xlnm#_filterdatabase")
{
dsSOW.Tables.Add(dr["TABLE_NAME"].ToString());
sWorkSheetsColl += dr["TABLE_NAME"].ToString() + ",";
iIndex++;
}
}
sWorkSheetsColl = sWorkSheetsColl.TrimEnd(',');
sWorkSheets = sWorkSheetsColl.Split(',');
dsSOW.AcceptChanges();
}
}
}
private void Get_Excel_Data()
{
for (int i = 0; i < sWorkSheets.Length; i++)
{
oCmd = new OleDbCommand("SELECT * FROM [" + sWorkSheets[i].TrimEnd() + "]", oConn);
oDa = new OleDbDataAdapter();
oDa.SelectCommand = oCmd;
oDa.Fill(dsSOW.Tables[sWorkSheets[i].ToString()]);
}
oConn.Close();
dsSOW.AcceptChanges();
}
public static void CreatePresentation(string filepath)
{
// Create a presentation at a specified file path. The presentation document type is pptx, by default.
PresentationDocument presentationDoc = PresentationDocument.Create(filepath, PresentationDocumentType.Presentation);
PresentationPart presentationPart = presentationDoc.AddPresentationPart();
presentationPart.Presentation = new Presentation();
CreatePresentationParts(presentationPart);
// Close the presentation handle
presentationDoc.Close();
}
private static void CreatePresentationParts(PresentationPart presentationPart)
{
SlideMasterIdList slideMasterIdList1 = new SlideMasterIdList(new SlideMasterId() { Id = (UInt32Value)2147483648U, RelationshipId = "rId1" });
SlideIdList slideIdList1 = new SlideIdList(new SlideId() { Id = (UInt32Value)256U, RelationshipId = "rId2" });
SlideSize slideSize1 = new SlideSize() { Cx = 9144000, Cy = 6858000, Type = SlideSizeValues.Screen4x3 };
NotesSize notesSize1 = new NotesSize() { Cx = 6858000, Cy = 9144000 };
DefaultTextStyle defaultTextStyle1 = new DefaultTextStyle();
presentationPart.Presentation.Append(slideMasterIdList1, slideIdList1, slideSize1, notesSize1, defaultTextStyle1);
SlidePart slidePart1;
SlideLayoutPart slideLayoutPart1;
SlideMasterPart slideMasterPart1;
ThemePart themePart1;
slidePart1 = CreateSlidePart(presentationPart);
slideLayoutPart1 = CreateSlideLayoutPart(slidePart1);
slideMasterPart1 = CreateSlideMasterPart(slideLayoutPart1);
themePart1 = CreateTheme(slideMasterPart1);
slideMasterPart1.AddPart(slideLayoutPart1, "rId1");
presentationPart.AddPart(slideMasterPart1, "rId1");
presentationPart.AddPart(themePart1, "rId5");
}
private static SlidePart CreateSlidePart(PresentationPart presentationPart)
{
SlidePart slidePart1 = presentationPart.AddNewPart<SlidePart>("rId2");
ImagePart imagePart = slidePart1.AddNewPart<ImagePart>("image/jpg", "rId2");
string filepath = @"C:\Users\302480\Documents\Visual Studio 2010\Projects\ppt\ppt\Source\Images\DDT.jpg";
FileStream stream = new FileStream(filepath, FileMode.Open);
imagePart.FeedData(stream);
stream.Close();
slidePart1.Slide = new Slide(
new CommonSlideData(
new ShapeTree(
new P.NonVisualGroupShapeProperties(
new P.NonVisualDrawingProperties() { Id = (UInt32Value)1U, Name = "" },
new P.NonVisualGroupShapeDrawingProperties(),
new ApplicationNonVisualDrawingProperties()),
new GroupShapeProperties(new TransformGroup()),
new P.Shape(
new P.NonVisualShapeProperties(
new P.NonVisualDrawingProperties() { Id = (UInt32Value)2U, Name = "Title 1" },
new P.NonVisualShapeDrawingProperties(new ShapeLocks() { NoGrouping = true }),
new ApplicationNonVisualDrawingProperties(new PlaceholderShape())),
new P.ShapeProperties(),
new P.TextBody(
new BodyProperties(),
new ListStyle(),
new Paragraph(new EndParagraphRunProperties() { Language = "en-US" }))))),
new ColorMapOverride(new MasterColorMapping()));
P.Picture picture = new P.Picture();
P.BlipFill blipFill = new P.BlipFill();
D.Blip blip = new D.Blip() { Embed = "rId2" };
Stretch stretch = new Stretch();
FillRectangle fillRectangle = new FillRectangle();
stretch.Append(fillRectangle);
blipFill.Append(blip);
blipFill.Append(stretch);
BlipExtensionList blipExtensionList1 = new BlipExtensionList();
BlipExtension blipExtension1 = new BlipExtension() { Uri = "{28A0092B-C50C-407E-A947-70E740481C1C}" };
UseLocalDpi useLocalDpi1 = new UseLocalDpi() { Val = false };
useLocalDpi1.AddNamespaceDeclaration("a14","http://schemas.microsoft.com/office/drawing/2010/main");
blipExtension1.Append(useLocalDpi1);
blipExtensionList1.Append(blipExtension1);
blip.Append(blipExtensionList1);
picture.Append(blipFill);
P.ShapeProperties shapeProperties1 = new P.ShapeProperties();
D.Transform2D transform2D1 = new D.Transform2D();
D.Offset offset1 = new D.Offset() { X = 667544L, Y = 648680L };
D.Extents extents1 = new D.Extents() { Cx = 5743848L, Cy = 4886743L };
transform2D1.Append(offset1);
transform2D1.Append(extents1);
D.PresetGeometry presetGeometry1 = new D.PresetGeometry() { Preset = D.ShapeTypeValues.Rectangle };
D.AdjustValueList adjustValueList1 = new D.AdjustValueList();
presetGeometry1.Append(adjustValueList1);
shapeProperties1.Append(transform2D1);
shapeProperties1.Append(presetGeometry1);
picture.Append(shapeProperties1);
slidePart1.Slide.CommonSlideData.ShapeTree.Append(picture);
return slidePart1;
}
private static SlideLayoutPart CreateSlideLayoutPart(SlidePart slidePart1)
{
SlideLayoutPart slideLayoutPart1 = slidePart1.AddNewPart<SlideLayoutPart>("rId1");
SlideLayout slideLayout = new SlideLayout(
new CommonSlideData(new ShapeTree(
new P.NonVisualGroupShapeProperties(
new P.NonVisualDrawingProperties() { Id = (UInt32Value)1U, Name = "" },
new P.NonVisualGroupShapeDrawingProperties(),
new ApplicationNonVisualDrawingProperties()),
new GroupShapeProperties(new TransformGroup()),
new P.Shape(
new P.NonVisualShapeProperties(
new P.NonVisualDrawingProperties() { Id = (UInt32Value)2U, Name = "" },
new P.NonVisualShapeDrawingProperties(new ShapeLocks() { NoGrouping = true }),
new ApplicationNonVisualDrawingProperties(new PlaceholderShape())),
new P.ShapeProperties(),
new P.TextBody(
new BodyProperties(),
new ListStyle(),
new Paragraph(new EndParagraphRunProperties()))))),
new ColorMapOverride(new MasterColorMapping()));
slideLayoutPart1.SlideLayout = slideLayout;
return slideLayoutPart1;
}
private static SlideMasterPart CreateSlideMasterPart(SlideLayoutPart slideLayoutPart1)
{
SlideMasterPart slideMasterPart1 = slideLayoutPart1.AddNewPart<SlideMasterPart>("rId1");
SlideMaster slideMaster = new SlideMaster(
new CommonSlideData(new ShapeTree(
new P.NonVisualGroupShapeProperties(
new P.NonVisualDrawingProperties() { Id = (UInt32Value)1U, Name = "" },
new P.NonVisualGroupShapeDrawingProperties(),
new ApplicationNonVisualDrawingProperties()),
new GroupShapeProperties(new TransformGroup()),
new P.Shape(
new P.NonVisualShapeProperties(
new P.NonVisualDrawingProperties() { Id = (UInt32Value)2U, Name = "Title Placeholder 1" },
new P.NonVisualShapeDrawingProperties(new ShapeLocks() { NoGrouping = true }),
new ApplicationNonVisualDrawingProperties(new PlaceholderShape() { Type = PlaceholderValues.Title })),
new P.ShapeProperties(),
new P.TextBody(
new BodyProperties(),
new ListStyle(),
new Paragraph())))),
new P.ColorMap() { Background1 = D.ColorSchemeIndexValues.Light1, Text1 = D.ColorSchemeIndexValues.Dark1, Background2 = D.ColorSchemeIndexValues.Light2, Text2 = D.ColorSchemeIndexValues.Dark2, Accent1 = D.ColorSchemeIndexValues.Accent1, Accent2 = D.ColorSchemeIndexValues.Accent2, Accent3 = D.ColorSchemeIndexValues.Accent3, Accent4 = D.ColorSchemeIndexValues.Accent4, Accent5 = D.ColorSchemeIndexValues.Accent5, Accent6 = D.ColorSchemeIndexValues.Accent6, Hyperlink = D.ColorSchemeIndexValues.Hyperlink, FollowedHyperlink = D.ColorSchemeIndexValues.FollowedHyperlink },
new SlideLayoutIdList(new SlideLayoutId() { Id = (UInt32Value)2147483649U, RelationshipId = "rId1" }),
new TextStyles(new TitleStyle(), new BodyStyle(), new OtherStyle()));
slideMasterPart1.SlideMaster = slideMaster;
return slideMasterPart1;
}
private static ThemePart CreateTheme(SlideMasterPart slideMasterPart1)
{
ThemePart themePart1 = slideMasterPart1.AddNewPart<ThemePart>("rId5");
D.Theme theme1 = new D.Theme() { Name = "Office Theme" };
D.ThemeElements themeElements1 = new D.ThemeElements(
new D.ColorScheme(
new D.Dark1Color(new D.SystemColor() { Val = D.SystemColorValues.WindowText, LastColor = "000000" }),
new D.Light1Color(new D.SystemColor() { Val = D.SystemColorValues.Window, LastColor = "FFFFFF" }),
new D.Dark2Color(new D.RgbColorModelHex() { Val = "1F497D" }),
new D.Light2Color(new D.RgbColorModelHex() { Val = "EEECE1" }),
new D.Accent1Color(new D.RgbColorModelHex() { Val = "4F81BD" }),
new D.Accent2Color(new D.RgbColorModelHex() { Val = "C0504D" }),
new D.Accent3Color(new D.RgbColorModelHex() { Val = "9BBB59" }),
new D.Accent4Color(new D.RgbColorModelHex() { Val = "8064A2" }),
new D.Accent5Color(new D.RgbColorModelHex() { Val = "4BACC6" }),
new D.Accent6Color(new D.RgbColorModelHex() { Val = "F79646" }),
new D.Hyperlink(new D.RgbColorModelHex() { Val = "0000FF" }),
new D.FollowedHyperlinkColor(new D.RgbColorModelHex() { Val = "800080" })) { Name = "Office" },
new D.FontScheme(
new D.MajorFont(
new D.LatinFont() { Typeface = "Calibri" },
new D.EastAsianFont() { Typeface = "" },
new D.ComplexScriptFont() { Typeface = "" }),
new D.MinorFont(
new D.LatinFont() { Typeface = "Calibri" },
new D.EastAsianFont() { Typeface = "" },
new D.ComplexScriptFont() { Typeface = "" })) { Name = "Office" },
new D.FormatScheme(
new D.FillStyleList(
new D.SolidFill(new D.SchemeColor() { Val = D.SchemeColorValues.PhColor }),
new D.GradientFill(
new D.GradientStopList(
new D.GradientStop(new D.SchemeColor(new D.Tint() { Val = 50000 },
new D.SaturationModulation() { Val = 300000 }) { Val = D.SchemeColorValues.PhColor }) { Position = 0 },
new D.GradientStop(new D.SchemeColor(new D.Tint() { Val = 37000 },
new D.SaturationModulation() { Val = 300000 }) { Val = D.SchemeColorValues.PhColor }) { Position = 35000 },
new D.GradientStop(new D.SchemeColor(new D.Tint() { Val = 15000 },
new D.SaturationModulation() { Val = 350000 }) { Val = D.SchemeColorValues.PhColor }) { Position = 100000 }
),
new D.LinearGradientFill() { Angle = 16200000, Scaled = true }),
new D.NoFill(),
new D.PatternFill(),
new D.GroupFill()),
new D.LineStyleList(
new D.Outline(
new D.SolidFill(
new D.SchemeColor(
new D.Shade() { Val = 95000 },
new D.SaturationModulation() { Val = 105000 }) { Val = D.SchemeColorValues.PhColor }),
new D.PresetDash() { Val = D.PresetLineDashValues.Solid })
{
Width = 9525,
CapType = D.LineCapValues.Flat,
CompoundLineType = D.CompoundLineValues.Single,
Alignment = D.PenAlignmentValues.Center
},
new D.Outline(
new D.SolidFill(
new D.SchemeColor(
new D.Shade() { Val = 95000 },
new D.SaturationModulation() { Val = 105000 }) { Val = D.SchemeColorValues.PhColor }),
new D.PresetDash() { Val = D.PresetLineDashValues.Solid })
{
Width = 9525,
CapType = D.LineCapValues.Flat,
CompoundLineType = D.CompoundLineValues.Single,
Alignment = D.PenAlignmentValues.Center
},
new D.Outline(
new D.SolidFill(
new D.SchemeColor(
new D.Shade() { Val = 95000 },
new D.SaturationModulation() { Val = 105000 }) { Val = D.SchemeColorValues.PhColor }),
new D.PresetDash() { Val = D.PresetLineDashValues.Solid })
{
Width = 9525,
CapType = D.LineCapValues.Flat,
CompoundLineType = D.CompoundLineValues.Single,
Alignment = D.PenAlignmentValues.Center
}),
new D.EffectStyleList(
new D.EffectStyle(
new D.EffectList(
new D.OuterShadow(
new D.RgbColorModelHex(
new D.Alpha() { Val = 38000 }) { Val = "000000" }) { BlurRadius = 40000L, Distance = 20000L, Direction = 5400000, RotateWithShape = false })),
new D.EffectStyle(
new D.EffectList(
new D.OuterShadow(
new D.RgbColorModelHex(
new D.Alpha() { Val = 38000 }) { Val = "000000" }) { BlurRadius = 40000L, Distance = 20000L, Direction = 5400000, RotateWithShape = false })),
new D.EffectStyle(
new D.EffectList(
new D.OuterShadow(
new D.RgbColorModelHex(
new D.Alpha() { Val = 38000 }) { Val = "000000" }) { BlurRadius = 40000L, Distance = 20000L, Direction = 5400000, RotateWithShape = false }))),
new D.BackgroundFillStyleList(
new D.SolidFill(new D.SchemeColor() { Val = D.SchemeColorValues.PhColor }),
new D.GradientFill(
new D.GradientStopList(
new D.GradientStop(
new D.SchemeColor(new D.Tint() { Val = 50000 },
new D.SaturationModulation() { Val = 300000 }) { Val = D.SchemeColorValues.PhColor }) { Position = 0 },
new D.GradientStop(
new D.SchemeColor(new D.Tint() { Val = 50000 },
new D.SaturationModulation() { Val = 300000 }) { Val = D.SchemeColorValues.PhColor }) { Position = 0 },
new D.GradientStop(
new D.SchemeColor(new D.Tint() { Val = 50000 },
new D.SaturationModulation() { Val = 300000 }) { Val = D.SchemeColorValues.PhColor }) { Position = 0 }),
new D.LinearGradientFill() { Angle = 16200000, Scaled = true }),
new D.GradientFill(
new D.GradientStopList(
new D.GradientStop(
new D.SchemeColor(new D.Tint() { Val = 50000 },
new D.SaturationModulation() { Val = 300000 }) { Val = D.SchemeColorValues.PhColor }) { Position = 0 },
new D.GradientStop(
new D.SchemeColor(new D.Tint() { Val = 50000 },
new D.SaturationModulation() { Val = 300000 }) { Val = D.SchemeColorValues.PhColor }) { Position = 0 }),
new D.LinearGradientFill() { Angle = 16200000, Scaled = true }))) { Name = "Office" });
theme1.Append(themeElements1);
theme1.Append(new D.ObjectDefaults());
theme1.Append(new D.ExtraColorSchemeList());
themePart1.Theme = theme1;
return themePart1;
}
I have word document.In that document has many style(like normal,heading1,heading2 etc).I want to Apply font size,font name for particular style using open XML.For example i want to apply font size,font name for normal style in that document using open XML
in c#.net or vb.net.please provide solution....
I have convert word automation with open Xml technology.I have add some word templates to single word document and populate values to fields in that document.in following scenario if single values for make,model,serial,year,nnumber and seat fields then no
problem for populate values to that field.but if more than one values available for that fields then i need to copy that particular range and paste below with table and populate values to that field.Dynamically how to populate for more than value (See image
below) to single field with loop using openXML?How to implement above scenario? please provide solution
I have an application that allows users (among other things) to align objects to chart labels. This app was originally written to function in COM where I was able to ask PowerPoint for Label.Left and Label.Top to get the position. I have rewritten
this app to work natively on the OpenXML files (.pptx, xlsx etc) and to my dismay it seems that the OpenXML does not store the label position - obviously it is dynamically rendered at display time by PowerPoint.
What I was looking for would have been in the Chart Part "/ppt/charts/chartn.xml" and would have been something like (for a Bar Chart):
/c:chartSpace/c:chart/c:plotArea/c:barChart/c:ser/c:dLbls/c:dLbl/p:xfrm with a:off and a:ext nodes. (Obviously the xfrm would have been in the c namespace).
Can you help me with any way to find out the X and Y position of the labels on a chart from the OpenXML?