<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://openxmldeveloper.org/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Formats</title><link>http://openxmldeveloper.org/discussions/formats/default.aspx</link><description>Discussions about working with different Open XML Formats</description><dc:language /><generator>Telligent Community 5.6.582.12783 (Build: 5.6.582.12783)</generator><item><title>Forum Post: Re: Adding Multiple Images At Set Location</title><link>http://openxmldeveloper.org/discussions/formats/f/13/p/6311/160878.aspx#160878</link><pubDate>Thu, 23 May 2013 12:09:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160878</guid><dc:creator>Dane Balia</dc:creator><description>&lt;p&gt;Thanks found the answer on the site.&lt;/p&gt; &lt;p&gt;&lt;a rel="nofollow" href="http://openxmldeveloper.org/blog/b/openxmldeveloper/archive/2013/02/11/inserting-an-image-into-a-bookmark-in-an-openxml-wordprocessingml-document.aspx"&gt;openxmldeveloper.org/.../inserting-an-image-into-a-bookmark-in-an-openxml-wordprocessingml-document.aspx&lt;/a&gt;&lt;/p&gt; </description></item><item><title>Forum Post: Re: Open Xml</title><link>http://openxmldeveloper.org/discussions/formats/f/14/p/6224/160874.aspx#160874</link><pubDate>Tue, 21 May 2013 14:56:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160874</guid><dc:creator>julix12</dc:creator><description>&lt;p&gt;Cool. thanks :)&amp;nbsp;&lt;a href="http://linkapp.me/yTD5K"&gt;&lt;span&gt;http://linkapp.me/yTD5K&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;</description></item><item><title>Forum Post: Require Help</title><link>http://openxmldeveloper.org/discussions/formats/f/13/p/6308/160870.aspx#160870</link><pubDate>Sat, 18 May 2013 07:14:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160870</guid><dc:creator>pankajbaviskar</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;  &lt;p&gt;&amp;nbsp;&lt;/p&gt;  &lt;p&gt;I am new to OpenXml , my requirement is i want to develop a word document which having text, tables and chart in that. i had written code for that , when i open word it gives unspecified Error.&lt;/p&gt;</description></item><item><title>Forum Post: Re: How do I know the size of a specific piece of text in a work document?</title><link>http://openxmldeveloper.org/discussions/formats/f/13/p/5833/160869.aspx#160869</link><pubDate>Fri, 17 May 2013 23:00:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160869</guid><dc:creator>jcordeiro</dc:creator><description>&lt;p&gt;Dear Jim,&lt;/p&gt; &lt;p&gt;Let me add some additional information.&lt;/p&gt; &lt;p&gt;Regarding point 1: you&amp;#39;re completely right about the text from the standard: it clear states that the default praragraph style should be applied if there is no paragraph style applied. On the other hand the information regarding the pstyle element states:&lt;/p&gt; &lt;p&gt;&amp;quot;If this element is omitted, or it references a style which does not exist, then no paragraph style shall be applied&lt;/p&gt; &lt;p&gt;to the current paragraph. As well, this property is ignored if the paragraph properties are part of a paragraph&lt;/p&gt; &lt;p&gt;style.&amp;quot; (ISO/IEC 29500-1:2012(E - &amp;nbsp;17.3.1.27)&lt;/p&gt; &lt;p&gt;This is against the first statement!!!&lt;/p&gt; &lt;p&gt;For the character style (also point 2) the behaviour of word is like this:&lt;/p&gt; &lt;p&gt;I change the default character style within Visual Studio (VS), (in my tests I added run properties with just the bold property inside) and when I open word, it completes ignore my changes. Then I change something inside the run with that style and after saving the document, word replaces the default character style with the following style (the original character default style) removing all run properties from the style:&lt;/p&gt; &lt;p&gt; &amp;lt;w:style w:type=&amp;quot;character&amp;quot; w:default=&amp;quot;1&amp;quot; w:styleId=&amp;quot;DefaultParagraphFont&amp;quot;&amp;gt;&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp;&amp;lt;w:name w:val=&amp;quot;Default Paragraph Font&amp;quot;/&amp;gt;&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp;&amp;lt;w:uiPriority w:val=&amp;quot;1&amp;quot;/&amp;gt;&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp;&amp;lt;w:semiHidden/&amp;gt;&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp;&amp;lt;w:unhideWhenUsed/&amp;gt;&lt;/p&gt; &lt;p&gt; &amp;nbsp;&amp;lt;/w:style&amp;gt;&lt;/p&gt; &lt;p&gt;Also, as I said before, Word keeps all run properties information for a character style in that specific style. In this case is not necessary to roll up styles. A simple test I made is to define within VS the size of a font in the run properties of character style &amp;quot;styleA&amp;quot; and no size information for character style &amp;quot;styleBinheritingFromA&amp;quot;. When I open word everything is correct within runs of both styles, but if I change something in the run with &amp;quot;styleBinheritingFromA&amp;quot; word changes this style with all information inherited from styleB that is missing. In this case my size property is added to style &amp;quot;styleBinheritingFromA&amp;quot;.&lt;/p&gt; &lt;p&gt;José&lt;/p&gt; </description></item><item><title>Forum Post: Re: DocumentBuilder dont find file create in runtime</title><link>http://openxmldeveloper.org/discussions/formats/f/13/p/6303/160862.aspx#160862</link><pubDate>Tue, 14 May 2013 20:16:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160862</guid><dc:creator>ClaudiaJS</dc:creator><description>&lt;p&gt;Thanks for answer, I want to say. With three procedures, i do, three differents files, after, i combine these files just created with other files already existing in the server, but when I do this, the procedure &amp;quot;DocumentBuilder.BuildDocument&amp;quot;, combine the files already existing in the server, but the three files, created before the execution of the procedure seems dont exist, and comes this error: &amp;quot;empty list error &amp;quot;. I see the files in the server, i can open the file and modify without problem.&lt;/p&gt; &lt;p&gt;I hope to be clear, I post the code for the generation of one file&lt;/p&gt; &lt;p&gt;Public Function GeneraFileArticoli(ByVal IdOffer As String, ByVal nomeCartella As String) As String&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim IndFileArticoli As String = &amp;quot;&amp;quot;&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Try&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim nomeDir As String = ConfigurationManager.AppSettings(&amp;quot;DirServer&amp;quot;)&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim TemplatePath As String = nomeDir + &amp;quot;\OpenXmlContent\ModelloGrid.docx&amp;quot;&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim OutputPath As String = nomeDir + &amp;quot;\&amp;quot; + nomeCartella + &amp;quot;\&amp;quot; + IdOffer + &amp;quot;-Articoli.docx&amp;quot;&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;File.Copy(TemplatePath, OutputPath)&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim db As New DBOfferteDataContext&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim varOfferta = From prod In db.spDoc(IdOffer)&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Using theDoc As WordprocessingDocument = WordprocessingDocument.Open(OutputPath, True)&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim body As Body = theDoc.MainDocumentPart.Document.Body&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;#39;***************************************** TABELLA CON DATI **************************************&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim mainPart As MainDocumentPart = theDoc.MainDocumentPart&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim ccWithTable As SdtBlock = mainPart.Document.Body.Descendants(Of SdtBlock)().Where(Function(e) e.SdtProperties.GetFirstChild(Of Tag)().Val = &amp;quot;ElencoProdotti&amp;quot;).[Single]()&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim theTable = ccWithTable.Descendants(Of Table)().Single()&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim theRow = theTable.Elements(Of TableRow)().Last()&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;For Each articolo In varOfferta&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim rowCopy As TableRow = DirectCast(theRow.CloneNode(True), TableRow)&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;rowCopy.Descendants(Of TableCell)().ElementAt(0).Append(New Paragraph(New Run(New Text(articolo.Kit.ToString()))))&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;rowCopy.Descendants(Of TableCell)().ElementAt(1).Append(New Paragraph(New Run(New Text(articolo.Codice.ToString()))))&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;rowCopy.Descendants(Of TableCell)().ElementAt(2).Append(New Paragraph(New Run(New Text(articolo.Prodotto.ToString()))))&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;rowCopy.Descendants(Of TableCell)().ElementAt(3).Append(New Paragraph(New Run(New Text(articolo.Incluso.ToString()))))&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;rowCopy.Descendants(Of TableCell)().ElementAt(4).Append(New Paragraph(New Run(New Text(articolo.Prezzo.ToString()))))&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;theTable.AppendChild(rowCopy)&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Next&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;theTable.RemoveChild(theRow)&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;mainPart.Document.Save()&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;IndFileArticoli = docOutputPath&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;End Using&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Catch ex As Exception&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dim Problema As String = ex.Message&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;End Try&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Return IndFileArticoli&lt;/p&gt; &lt;p&gt; &amp;nbsp; &amp;nbsp;End Function&lt;/p&gt; &lt;p&gt;Thank&amp;#39;s in advance&lt;/p&gt; &lt;p&gt;Claudia&lt;/p&gt; </description></item><item><title>Forum Post: Re: Can the Presentation Builder be used without the USING() { } Statement?</title><link>http://openxmldeveloper.org/discussions/formats/f/15/p/6302/160860.aspx#160860</link><pubDate>Tue, 14 May 2013 17:16:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160860</guid><dc:creator>YasiduY3K</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;  &lt;p&gt;I did a small modification to the presentation builder.&lt;/p&gt;  &lt;p&gt;Instead of creating an output file from scratch (OpenXmlMemoryStreamDocument), i&amp;#39;m using&amp;nbsp;PresentationDocument.Open() to create an existing file and clone files from another presentation to it.&lt;/p&gt;  &lt;p&gt;The approach I took was, (PresentationBuilder modification),&lt;/p&gt;  &lt;p&gt;(Base presentation denoted as &amp;nbsp;B, to be cloned presentation is denoted as C)&lt;/p&gt;  &lt;p&gt;Modify&amp;nbsp;BuildPresentation() method to use B as the output file.&lt;/p&gt;  &lt;p&gt;Use C as the SlideSource.&lt;/p&gt;  &lt;p&gt;Comment out&amp;nbsp;CopyPresentationParts() method as the output is not getting built from scratch.&lt;/p&gt;  &lt;p&gt;The resultant output throws an error!&lt;/p&gt;  &lt;p&gt;Base presentation:&lt;/p&gt;  &lt;p&gt;&lt;img src="http://openxmldeveloper.org/resized-image.ashx/__size/550x0/__key/communityserver-discussions-components-files/15/2251.Base.JPG" border="0" alt=" " /&gt;&lt;/p&gt;  &lt;p&gt;&amp;nbsp;&lt;/p&gt;  &lt;p&gt;ToBeCloned:&lt;/p&gt;  &lt;p&gt;&lt;img src="http://openxmldeveloper.org/resized-image.ashx/__size/550x0/__key/communityserver-discussions-components-files/15/8475.ToBeCloned.JPG" border="0" alt=" " /&gt;&lt;/p&gt;  &lt;p&gt;Error:&lt;/p&gt;  &lt;p&gt;&lt;img src="http://openxmldeveloper.org/resized-image.ashx/__size/550x0/__key/communityserver-discussions-components-files/15/0488.Error.JPG" border="0" alt=" " /&gt;&lt;/p&gt;  &lt;p&gt;&amp;nbsp;&lt;/p&gt;  &lt;p&gt;Output:&lt;/p&gt;  &lt;p&gt;&lt;img src="http://openxmldeveloper.org/resized-image.ashx/__size/550x0/__key/communityserver-discussions-components-files/15/4606.output.JPG" border="0" alt=" " /&gt;&lt;/p&gt;  &lt;p&gt;&amp;nbsp;&lt;/p&gt;  &lt;p&gt;After some checking i found out that the two master slides has contains two separate layout slides with the same ID!&lt;/p&gt;  &lt;p&gt;Issue:&lt;/p&gt;  &lt;p&gt;&lt;img src="http://openxmldeveloper.org/resized-image.ashx/__size/550x0/__key/communityserver-discussions-components-files/15/6567.Cause.JPG" border="0" alt=" " /&gt;&lt;/p&gt;  &lt;p&gt;After browsing through, for similar situations, I was able to apply the following as a fix.&lt;/p&gt;  &lt;p&gt;In CopyMasterSlides(), at the end, use&amp;nbsp;FixSlideLayoutIds() method to re arrange the layout slide id&amp;#39;s.&lt;/p&gt;  &lt;p&gt;&amp;nbsp;&lt;/p&gt;  &lt;p&gt;A sample code with fix is attached as Post3.zip&lt;/p&gt;  &lt;p&gt;Hope this will help any future enhancement of the PresentationBuilder code as well as anyone with a similar problem, while trying to experiment with its code.&lt;/p&gt;  &lt;p&gt;Cheers,&lt;/p&gt;  &lt;p&gt;YasiduY3K&lt;/p&gt;</description></item><item><title>Forum Post: Re: merging word-documents with DocumentFormat.OpenXml(c#)</title><link>http://openxmldeveloper.org/discussions/formats/f/13/p/5371/160845.aspx#160845</link><pubDate>Thu, 09 May 2013 09:18:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160845</guid><dc:creator>Tennyson</dc:creator><description>&lt;p&gt;Hi, i happened to used this &lt;strong&gt;&lt;a href="http://www.rasteredge.com/how-to/csharp-imaging/word-merge/"&gt;word document merging sdk in c#&lt;/a&gt;&lt;/strong&gt; to help my image programming work which includes the merge of two or more word documents, it works well, have a try. And, what&amp;#39;s more, it also can &lt;strong&gt;&lt;a href="http://www.rasteredge.com/how-to/csharp-imaging/pdf-merge/"&gt;merge pdf documents&lt;/a&gt;&lt;/strong&gt;, which i thinks you maybe also need this source.&lt;/p&gt;</description></item><item><title>Forum Post: Using Custom UI Editor if statement when file name is .pptx</title><link>http://openxmldeveloper.org/discussions/formats/f/15/p/6296/160843.aspx#160843</link><pubDate>Thu, 09 May 2013 08:47:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160843</guid><dc:creator>y0gster</dc:creator><description>&lt;p&gt;i just found this Custom UI Editor while searching for a way to have an onload event on Powerpoint. Now I need is an if statement in the UI editor that would prevent it from running when the file extension is pptx. Here is the line of code im using in customui:  &lt;div&gt;&lt;span style="font-size:xx-small;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;  &amp;nbsp;&lt;/p&gt;  &lt;p&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;  &lt;pre class="prettyprint"&gt;&amp;lt;customUI xmlns=&amp;quot;http://schemas.microsoft.com/office/2006/01/customui&amp;quot;   onLoad=&amp;quot;onLoadCode&amp;quot; &amp;gt;  &amp;lt;/customUI&amp;gt;&lt;/pre&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;  &lt;p&gt;&amp;nbsp;&lt;/p&gt;  &lt;/span&gt;I can write the code in vba but here in xml im totally lost. What I was thinking was something like this which I wrote in vba:&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;  &lt;pre class="prettyprint"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;&lt;span style="color:#0000ff;"&gt;if right(filename,4) = &amp;quot;pptm&amp;quot; then  onLoad  =&amp;quot;onLoadCode&amp;quot;   end if&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;  &lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Forum Post: Re: Applying a Slide Master to a Presentation</title><link>http://openxmldeveloper.org/discussions/formats/f/15/p/1300/160833.aspx#160833</link><pubDate>Thu, 09 May 2013 04:35:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160833</guid><dc:creator>YasiduY3K</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt; &lt;p&gt;Aspose is faster. but they sucks!&lt;/p&gt; &lt;p&gt;I tried using Aspose for my projects, but they always throws out errors. I got errors with cloning, slidenumbering, powerpoint object formatting etc.&lt;/p&gt; &lt;p&gt;May be it&amp;#39;s because of the earliest version of their PPTX version, but I was ultimately fed up providing them sample codes to clarify the issues and waiting for long ETA&amp;#39;s till they come up with fixes.&lt;/p&gt; &lt;p&gt;But there powerpoint 03 version is really good.&lt;/p&gt; &lt;p&gt;My advice is stick with openxml, even u encounter an issue, you will have a code base to work it out.&lt;/p&gt; </description></item><item><title>Forum Post: Re: Removing images from a PPTX (and not breaking any relations)</title><link>http://openxmldeveloper.org/discussions/formats/f/15/p/6248/160830.aspx#160830</link><pubDate>Wed, 08 May 2013 17:50:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160830</guid><dc:creator>Eric White</dc:creator><description>&lt;p&gt;You will be amazed at how fast it is, though. &amp;nbsp;Once you write the correct code, it still will operate nearly instantaneously.&lt;/p&gt; </description></item><item><title>Forum Post: Re: Copy SlideMasterlayout element into the Slide</title><link>http://openxmldeveloper.org/discussions/formats/f/15/p/6273/160828.aspx#160828</link><pubDate>Wed, 08 May 2013 17:46:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160828</guid><dc:creator>Eric White</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt; &lt;p&gt;I&amp;#39;ve put together a PresentationBuilder resource center (&lt;a rel="nofollow" href="http://openxmldeveloper.org/wiki/w/wiki/presentationbuilder.aspx"&gt;openxmldeveloper.org/.../presentationbuilder.aspx&lt;/a&gt;) that contains a link to download the code, as well as links to the various screen-casts that you will want to watch. &amp;nbsp;You can learn a lot about PresentationML if you watch those screen-casts.&lt;/p&gt; &lt;p&gt;Best, Eric&lt;/p&gt; </description></item><item><title>Forum Post: Re: newMasterPart.SlideMaster.Preserve = false, is not working</title><link>http://openxmldeveloper.org/discussions/formats/f/15/p/6291/160822.aspx#160822</link><pubDate>Wed, 08 May 2013 11:42:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160822</guid><dc:creator>Eric White</dc:creator><description>&lt;p&gt;Hi, I&amp;#39;ll take a look at this tomorrow.&lt;/p&gt; &lt;p&gt;-Eric&lt;/p&gt; </description></item><item><title>Forum Post: Re: The presentation builder corrupts a presentation</title><link>http://openxmldeveloper.org/discussions/formats/f/15/p/6267/160818.aspx#160818</link><pubDate>Wed, 08 May 2013 10:03:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160818</guid><dc:creator>YasiduY3K</dc:creator><description>&lt;p&gt;Thanks Eric&lt;/p&gt; &lt;p&gt;Cheers, Yasiduy3K&lt;/p&gt; </description></item><item><title>Forum Post: Re: Tricky: MS Word vs Google Docs: Numbering starts at 2 whilst w:start w:val="1"/ </title><link>http://openxmldeveloper.org/discussions/formats/f/13/p/6223/160798.aspx#160798</link><pubDate>Mon, 06 May 2013 16:31:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160798</guid><dc:creator>Eric White</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;  &lt;p&gt;You are absolutely right, numbering is tricky. &amp;nbsp;Some time ago, I wrote an article on MSDN that details exactly how numbering works:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/office/ee922775.aspx" rel="nofollow"&gt;msdn.microsoft.com/.../ee922775.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;Further, I wrote a module, ListItemRetriever.cs, which is part of PowerTools for Open XML, which retrieves the &amp;quot;List Item&amp;quot; for each and every paragraph, if the paragraph has a list item.&lt;/p&gt;  &lt;p&gt;I was going to run ListItemRetriever on your document, but it looks like the document that you attached is empty. &amp;nbsp;But I put together the same example, and ListItemRetriever returns the correct values. &amp;nbsp;My document looks like this:&lt;/p&gt;  &lt;p&gt;&lt;img border="0" src="http://openxmldeveloper.org/cfs-file.ashx/__key/communityserver-discussions-components-files/13/1184.NumDoc.png" alt=" " /&gt;&lt;/p&gt;  &lt;p&gt;The code to exercise ListItemRetriever.cs looks like this:&lt;/p&gt;  &lt;p&gt;  &lt;pre class="prettyprint"&gt;using System;  using System.Collections.Generic;  using System.Linq;  using System.Text;  using System.Threading.Tasks;  using DocumentFormat.OpenXml.Packaging;  using OpenXmlPowerTools;    class Program  {      static void Main(string[] args)      {          using (WordprocessingDocument wDoc = WordprocessingDocument.Open(&amp;quot;../../outlineNumbers_OpenXML.docx&amp;quot;, false))          {              foreach (var para in wDoc.MainDocumentPart.GetXDocument().Descendants(W.p))              {                  string listItem = ListItemRetriever.RetrieveListItem(wDoc, para, &amp;quot;-&amp;quot;);                  string text = para.Descendants(W.t).Select(t =&amp;gt; (string)t).StringConcatenate();                  string line = string.Format(&amp;quot;{0} {1}&amp;quot;, listItem, text);                  Console.WriteLine(line);              }          }      }  }  &lt;/pre&gt;  &lt;/p&gt;  &lt;p&gt;When you run this example on the above document, it produces:&lt;/p&gt;  &lt;p&gt;  &lt;pre class="prettyprint"&gt;i)  i  ii)  ii  iii)  iii  2)  2. LOOK HERE  3)  3&lt;/pre&gt;  If I recall correctly, I believe it works this way because there is an implied level 0 for those level 1 list items. &amp;nbsp;But I can&amp;#39;t recall exactly (It&amp;#39;s been a number of years). &amp;nbsp;If you go through that MSDN article in full detail, it will explain the issue, I believe.&lt;/p&gt;  &lt;p&gt;When you build the example, you will need the following modules from PowerTools for Open XML:&lt;/p&gt;  &lt;ul&gt;  &lt;li&gt;&lt;span style="font-size:12px;"&gt;ListItemRetriever.cs&lt;/span&gt;&lt;/li&gt;  &lt;li&gt;&lt;span style="font-size:12px;"&gt;PtOpenXmlDocument.cs&lt;/span&gt;&lt;/li&gt;  &lt;li&gt;&lt;span style="font-size:12px;"&gt;PtOpenXmlUtil.cs&lt;/span&gt;&lt;/li&gt;  &lt;li&gt;&lt;span style="font-size:12px;"&gt;PtUtil.cs&lt;/span&gt;&lt;/li&gt;  &lt;/ul&gt;  &lt;p&gt;You can get those modules from the PowerTools core zip file at &lt;a href="http://powertools.codeplex.com"&gt;http://powertools.codeplex.com&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;Those modules are also, of course, in the larger package that you can use to build the cmdlets.&lt;/p&gt;  &lt;p&gt;&lt;span style="font-size:12px;"&gt;Best, Eric&lt;/span&gt;&lt;/p&gt;</description></item><item><title>Forum Post: Re: Is it possible to use Custom XML tags?</title><link>http://openxmldeveloper.org/discussions/formats/f/13/p/6232/160797.aspx#160797</link><pubDate>Mon, 06 May 2013 16:13:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160797</guid><dc:creator>Eric White</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;  &lt;p&gt;The best approach is to wrap your paragraphs with content controls. &amp;nbsp;Take a look at this screen-cast:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://openxmldeveloper.org/blog/b/openxmldeveloper/archive/2011/10/03/custom-xml-parts-and-content-controls.aspx" rel="nofollow"&gt;openxmldeveloper.org/.../custom-xml-parts-and-content-controls.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;You also can look at this screen-cast with information about associating additional data with each content control:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.technet.com/b/gray_knowlton/archive/2010/01/15/associating-data-with-content-controls.aspx"&gt;http://blogs.technet.com/b/gray_knowlton/archive/2010/01/15/associating-data-with-content-controls.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;&lt;span style="font-size:12px;"&gt;Also, if you haven&amp;#39;t done so yet, I recommend watching the intro to Open XML screen-casts:&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;a href="http://openxmldeveloper.org/wiki/w/wiki/introduction-to-open-xml.aspx" rel="nofollow"&gt;openxmldeveloper.org/.../introduction-to-open-xml.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;And also the WordprocessingML screen-casts:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://openxmldeveloper.org/wiki/w/wiki/introduction-to-wordprocessingml.aspx" rel="nofollow"&gt;openxmldeveloper.org/.../introduction-to-wordprocessingml.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;Cheers, Eric&lt;/p&gt;</description></item><item><title>Forum Post: Re: Embedded Excel spreadsheet in Word Document - cannot update data</title><link>http://openxmldeveloper.org/discussions/formats/f/14/p/6237/160796.aspx#160796</link><pubDate>Mon, 06 May 2013 16:03:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160796</guid><dc:creator>Eric White</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt; &lt;p&gt;Open XML does not have a class that can automatically update the image that is displayed for the embedded Excel workbook. &amp;nbsp;You will need to generate this image yourself.&lt;/p&gt; &lt;p&gt;I have on my (long) list a project to generate a thumbnail for an Excel spreadsheet. &amp;nbsp;There would be a number of options so that you could control this process. &amp;nbsp;This is part of a larger project to do a bit of rendering of an Excel spreadsheet from the markup. &amp;nbsp;Then, you could use this code to generate the thumbnail and update the image.&lt;/p&gt; &lt;p&gt;You may be interested in the following screen-cast, which discusses the plumbing of embedding an Excel workbook in a document, in detail:&lt;/p&gt; &lt;p&gt;&lt;a rel="nofollow" href="http://openxmldeveloper.org/blog/b/openxmldeveloper/archive/2013/02/20/screen-cast-exploring-the-structure-of-embedded-spreadsheets-in-word-documents.aspx"&gt;openxmldeveloper.org/.../screen-cast-exploring-the-structure-of-embedded-spreadsheets-in-word-documents.aspx&lt;/a&gt;&lt;/p&gt; &lt;p&gt;I wish that I had a better answer for you, but I don&amp;#39;t. &amp;nbsp;You just need to create a new bitmap, write the graphics into the bitmap that you want, serialize that bitmap into the appropriate part in the word document, and then your embedded workbook with have the appearance that you want.&lt;/p&gt; &lt;p&gt;Best, Eric&lt;/p&gt; </description></item><item><title>Forum Post: Re: Grouping Excel rows using open xml</title><link>http://openxmldeveloper.org/discussions/formats/f/14/p/6239/160793.aspx#160793</link><pubDate>Mon, 06 May 2013 15:35:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160793</guid><dc:creator>Eric White</dc:creator><description>&lt;p&gt;Hi Ravi,&lt;/p&gt;  &lt;p&gt;You certainly can group rows. &amp;nbsp;I haven&amp;#39;t yet seen any good examples on doing this with Open XML, but it is certainly doable.&lt;/p&gt;  &lt;p&gt;One approach to use is as follows:&lt;/p&gt;  &lt;ul&gt;  &lt;li&gt;&lt;span style="font-size:12px;"&gt;Create your workbook without any grouping&lt;/span&gt;&lt;/li&gt;  &lt;li&gt;&lt;span style="font-size:12px;"&gt;Save away a copy of the workbook&lt;/span&gt;&lt;/li&gt;  &lt;li&gt;&lt;span style="font-size:12px;"&gt;Copy to a new name&lt;/span&gt;&lt;/li&gt;  &lt;li&gt;&lt;span style="font-size:12px;"&gt;Modify the new workbook, grouping the rows, and doing nothing else other than grouping the rows.&lt;/span&gt;&lt;/li&gt;  &lt;li&gt;&lt;span style="font-size:12px;"&gt;Use the Open XML SDK productivity tool to compare the two files. You can then see exactly the markup that you need to produce in order to group rows.&lt;/span&gt;&lt;/li&gt;  &lt;/ul&gt;  &lt;p&gt;If you haven&amp;#39;t done so yet, I recommend viewing the introductory screen-casts on Open XML:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://openxmldeveloper.org/wiki/w/wiki/introduction-to-open-xml.aspx"&gt;http://openxmldeveloper.org/wiki/w/wiki/introduction-to-open-xml.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;Also:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://openxmldeveloper.org/wiki/w/wiki/introduction-to-spreadsheetml.aspx"&gt;http://openxmldeveloper.org/wiki/w/wiki/introduction-to-spreadsheetml.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;&lt;span style="font-size:12px;"&gt;While the following is on PresentationML, it is relevant:&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;a href="http://openxmldeveloper.org/blog/b/openxmldeveloper/archive/2013/01/31/how-to-research-open-xml-presentationml.aspx"&gt;How to Research Open XML PresentationML&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;Also view this video:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://ericwhite.com/blog/2011/04/01/how-to-research-open-xml-markup/"&gt;How to Research Open XML Markup&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;-Eric&lt;/p&gt;</description></item><item><title>Forum Post: Re: Multiple OleObjects (Linked Objects) are not getting merged properly using DocumentBuilder</title><link>http://openxmldeveloper.org/discussions/formats/f/13/p/6243/160792.aspx#160792</link><pubDate>Mon, 06 May 2013 15:24:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160792</guid><dc:creator>Eric White</dc:creator><description>&lt;p&gt;Hi Fenil,&lt;/p&gt; &lt;p&gt;I am going to commence on PowerTools 3.0 in a couple of months (it&amp;#39;s going to be cool!). &amp;nbsp;I will definitely address this issue with that version.&lt;/p&gt; &lt;p&gt;Cheers, Eric&lt;/p&gt; </description></item><item><title>Forum Post: Re: How does powerpoint link txbody formatting from the slide to a slidelayout/master</title><link>http://openxmldeveloper.org/discussions/formats/f/15/p/1301/160777.aspx#160777</link><pubDate>Sun, 05 May 2013 10:10:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160777</guid><dc:creator>miktro</dc:creator><description>&lt;p&gt;I found a very helpful page today (published on Feb 11 2013) listing many corrections and explanations of OOXML behaviour in MS Office.&lt;/p&gt; &lt;p&gt;&lt;a rel="nofollow" href="http://msdn.microsoft.com/en-us/library/ee908652(v=office.12).aspx"&gt;msdn.microsoft.com/.../ee908652(v=office.12).aspx&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;This lists 1873 pages of corrections to the OOXML specification - many of which directly contradict the specification.&lt;/p&gt; &lt;p&gt;The main implication of these pages seems to be that the OOXML specification cannot be relied on to determine the behaviour of a document when used by MS Office.&lt;/p&gt; &lt;p&gt;If you find a discrepancy it may well be that Office is not obeying the specification - or is using it&amp;#39;s own defaults.&lt;/p&gt; &lt;p&gt;And if you rely on the specification to write conforming documents to be read by MS Office you may get surprising behaviour.&lt;/p&gt; &lt;p&gt;After spending over a month trying to determine default formatting values using the specification I am on the point of giving up as it seems that whatever I deduce may fail in future when implmenting a specific case that I have not compared to MS Office behaviour.&lt;/p&gt; &lt;p&gt;It seems one of the main purposes of the standard = to enable documents to be read in 10+ years when all related software has perished = is now invalid.&lt;/p&gt; &lt;p&gt;We will have to revert to scribing documents on parchment to ensure anything is readable in 1000 years.&lt;/p&gt; </description></item><item><title>Forum Post: Re: How to group several Shapes into a GroupShape Object</title><link>http://openxmldeveloper.org/discussions/formats/f/15/p/6275/160768.aspx#160768</link><pubDate>Thu, 02 May 2013 13:57:00 GMT</pubDate><guid isPermaLink="false">1ff61f26-0981-41c7-ad52-ff725e9b1da8:160768</guid><dc:creator>denlar</dc:creator><description>&lt;p&gt;Hello again,&lt;/p&gt;  &lt;p&gt;I found an ugly way to perform the grouping action. Since it&amp;#39;s really ugly, if anyone suggest better code I will read it with joy&lt;/p&gt;  &lt;p&gt;&amp;nbsp;&lt;/p&gt;  &lt;p&gt;  &lt;pre class="prettyprint"&gt;//Create an empty GroupShape          public GroupShape GetGroupShape(UInt32Value ui32)          {              GroupShape grpShape = new GroupShape();              NonVisualGroupShapeProperties nonVisualGroupShapeProperties = new NonVisualGroupShapeProperties(                      new NonVisualDrawingProperties(){ Id = ui32, Name = &amp;quot;Group &amp;quot;+ui32 },                      new NonVisualGroupShapeDrawingProperties(),                      new ApplicationNonVisualDrawingProperties()                      );              // Initialize dimension to 0,0 and position to 0,0              GroupShapeProperties groupShapeProperties = new GroupShapeProperties();              A.TransformGroup tfg = new A.TransformGroup(                      new A.Offset() { X = 0L, Y = 0L },                      new A.Extents() { Cx = 0L, Cy = 0L },                      new A.ChildOffset() { X = 0L, Y = 0L },                      new A.ChildExtents() { Cx = 0L, Cy = 0L });              groupShapeProperties.Append(tfg);                grpShape.Append(nonVisualGroupShapeProperties);              grpShape.Append(groupShapeProperties);                return grpShape;          }            //Grouping method          public GroupShape GroupAllShapes(IList&amp;lt;Shape&amp;gt; allShapes, IList&amp;lt;GroupShape&amp;gt; allGrpShape, UInt32Value idGroupShape)          {              GroupShape gs = GetGroupShape(idGroupShape);              int shapeCount = 0;              foreach (Shape s in allShapes)              {                  AddOpenXMLElement(gs, s, shapeCount);                  shapeCount++;                  //gs.;              }                foreach (GroupShape grpShape in allGrpShape)              {                  AddOpenXMLElement(gs, grpShape, shapeCount);                  shapeCount++;                  //gs.;              }                shapeCount++;                return gs;          }&lt;/pre&gt;  &lt;/p&gt;  &lt;p&gt;Ok now the AddOpenXMLElement method has to add the Shape or GroupShape but also to keep the GroupShape dimension and position up to date :&lt;/p&gt;  &lt;p&gt;  &lt;pre class="prettyprint"&gt;// Add a Shape or GroupShape to the given GroupeShape          // Actualize the dimension &amp;amp; Position of the final GroupeShape          public void AddOpenXMLElement(GroupShape gs, OpenXmlElement shape, int shapeCount)          {                            if (shape.GetType() == typeof(Shape))              {                  Shape s  = (Shape)shape;                  gs.Append(s);                                    if (shapeCount == 0) //1st shape added =&amp;gt; Initialization of the GroupShape properties                  {                      gs.GroupShapeProperties.TransformGroup.Offset.X = s.ShapeProperties.Transform2D.Offset.X;                      gs.GroupShapeProperties.TransformGroup.Offset.Y = s.ShapeProperties.Transform2D.Offset.Y;                      gs.GroupShapeProperties.TransformGroup.ChildOffset.X = s.ShapeProperties.Transform2D.Offset.X;                      gs.GroupShapeProperties.TransformGroup.ChildOffset.Y = s.ShapeProperties.Transform2D.Offset.Y;                        gs.GroupShapeProperties.TransformGroup.Extents.Cx = s.ShapeProperties.Transform2D.Extents.Cx;                      gs.GroupShapeProperties.TransformGroup.Extents.Cy = s.ShapeProperties.Transform2D.Extents.Cy;                      gs.GroupShapeProperties.TransformGroup.ChildExtents.Cx = s.ShapeProperties.Transform2D.Extents.Cx;                      gs.GroupShapeProperties.TransformGroup.ChildExtents.Cy = s.ShapeProperties.Transform2D.Extents.Cy;                  } else                  {                      //OFFSET PART (position)                      if (s.ShapeProperties.Transform2D.Offset.X &amp;lt; gs.GroupShapeProperties.TransformGroup.Offset.X)                      {                          gs.GroupShapeProperties.TransformGroup.Offset.X = s.ShapeProperties.Transform2D.Offset.X;                          gs.GroupShapeProperties.TransformGroup.ChildOffset.X = s.ShapeProperties.Transform2D.Offset.X;                      }                      if (s.ShapeProperties.Transform2D.Offset.Y &amp;lt; gs.GroupShapeProperties.TransformGroup.Offset.Y)                      {                          gs.GroupShapeProperties.TransformGroup.Offset.Y = s.ShapeProperties.Transform2D.Offset.Y;                          gs.GroupShapeProperties.TransformGroup.ChildOffset.Y = s.ShapeProperties.Transform2D.Offset.Y;                      }                      //EXTENTS PART (dimension)                      if ((s.ShapeProperties.Transform2D.Offset.X.Value + s.ShapeProperties.Transform2D.Extents.Cx.Value) &amp;gt; (gs.GroupShapeProperties.TransformGroup.Offset.X.Value + gs.GroupShapeProperties.TransformGroup.Extents.Cx.Value))                      {                          gs.GroupShapeProperties.TransformGroup.Extents.Cx = s.ShapeProperties.Transform2D.Offset.X - gs.GroupShapeProperties.TransformGroup.Offset.X + s.ShapeProperties.Transform2D.Extents.Cx;                          gs.GroupShapeProperties.TransformGroup.ChildExtents.Cx = s.ShapeProperties.Transform2D.Offset.X - gs.GroupShapeProperties.TransformGroup.Offset.X + s.ShapeProperties.Transform2D.Extents.Cx;                      }                      if ((s.ShapeProperties.Transform2D.Offset.Y.Value + s.ShapeProperties.Transform2D.Extents.Cy.Value) &amp;gt; (gs.GroupShapeProperties.TransformGroup.Offset.Y.Value + gs.GroupShapeProperties.TransformGroup.Extents.Cy.Value))                      {                          gs.GroupShapeProperties.TransformGroup.Extents.Cy = s.ShapeProperties.Transform2D.Offset.Y - gs.GroupShapeProperties.TransformGroup.Offset.Y + s.ShapeProperties.Transform2D.Extents.Cy;                          gs.GroupShapeProperties.TransformGroup.ChildExtents.Cy = s.ShapeProperties.Transform2D.Offset.Y - gs.GroupShapeProperties.TransformGroup.Offset.Y + s.ShapeProperties.Transform2D.Extents.Cy;                      }                  }              }                if (shape.GetType() == typeof(GroupShape))              {                  GroupShape grpShape = (GroupShape)shape;                  gs.Append(grpShape);                  if (shapeCount == 0) //1st shape added =&amp;gt; Initialization of the GroupShape properties                  {                      gs.GroupShapeProperties.TransformGroup.Offset.X = grpShape.GroupShapeProperties.TransformGroup.Offset.X;                      gs.GroupShapeProperties.TransformGroup.Offset.Y = grpShape.GroupShapeProperties.TransformGroup.Offset.Y;                      gs.GroupShapeProperties.TransformGroup.ChildOffset.X = grpShape.GroupShapeProperties.TransformGroup.Offset.X;                      gs.GroupShapeProperties.TransformGroup.ChildOffset.Y = grpShape.GroupShapeProperties.TransformGroup.Offset.Y;                        gs.GroupShapeProperties.TransformGroup.Extents.Cx = grpShape.GroupShapeProperties.TransformGroup.Extents.Cx;                      gs.GroupShapeProperties.TransformGroup.Extents.Cy = grpShape.GroupShapeProperties.TransformGroup.Extents.Cy;                      gs.GroupShapeProperties.TransformGroup.ChildExtents.Cx = grpShape.GroupShapeProperties.TransformGroup.Extents.Cx;                      gs.GroupShapeProperties.TransformGroup.ChildExtents.Cy = grpShape.GroupShapeProperties.TransformGroup.Extents.Cy;                    } else                  {                      //OFFSET PART (position)                      if (grpShape.GroupShapeProperties.TransformGroup.Offset.X &amp;lt; gs.GroupShapeProperties.TransformGroup.Offset.X)                      {                          gs.GroupShapeProperties.TransformGroup.Offset.X = grpShape.GroupShapeProperties.TransformGroup.Offset.X;                          gs.GroupShapeProperties.TransformGroup.ChildOffset.X = grpShape.GroupShapeProperties.TransformGroup.Offset.X;                      }                      if (grpShape.GroupShapeProperties.TransformGroup.Offset.Y &amp;lt; gs.GroupShapeProperties.TransformGroup.Offset.Y)                      {                          gs.GroupShapeProperties.TransformGroup.Offset.Y = grpShape.GroupShapeProperties.TransformGroup.Offset.Y;                          gs.GroupShapeProperties.TransformGroup.ChildOffset.Y = grpShape.GroupShapeProperties.TransformGroup.Offset.Y;                      }                      //EXTENTS PART (dimension)                      if ((grpShape.GroupShapeProperties.TransformGroup.Offset.X.Value + grpShape.GroupShapeProperties.TransformGroup.Extents.Cx.Value) &amp;gt; (gs.GroupShapeProperties.TransformGroup.Offset.X.Value + gs.GroupShapeProperties.TransformGroup.Extents.Cx.Value))                      {                          gs.GroupShapeProperties.TransformGroup.Extents.Cx = grpShape.GroupShapeProperties.TransformGroup.Offset.X - gs.GroupShapeProperties.TransformGroup.Offset.X + grpShape.GroupShapeProperties.TransformGroup.Extents.Cx;                          gs.GroupShapeProperties.TransformGroup.ChildExtents.Cx = grpShape.GroupShapeProperties.TransformGroup.Offset.X - gs.GroupShapeProperties.TransformGroup.Offset.X + grpShape.GroupShapeProperties.TransformGroup.Extents.Cx;                      }                      if ((grpShape.GroupShapeProperties.TransformGroup.Offset.Y.Value + grpShape.GroupShapeProperties.TransformGroup.Extents.Cy.Value) &amp;gt; (gs.GroupShapeProperties.TransformGroup.Offset.Y.Value + gs.GroupShapeProperties.TransformGroup.Extents.Cy.Value))                      {                          gs.GroupShapeProperties.TransformGroup.Extents.Cy = grpShape.GroupShapeProperties.TransformGroup.Offset.Y - gs.GroupShapeProperties.TransformGroup.Offset.Y + grpShape.GroupShapeProperties.TransformGroup.Extents.Cy;                          gs.GroupShapeProperties.TransformGroup.ChildExtents.Cy = grpShape.GroupShapeProperties.TransformGroup.Offset.Y - gs.GroupShapeProperties.TransformGroup.Offset.Y + grpShape.GroupShapeProperties.TransformGroup.Extents.Cy;                      }                  }              }            }&lt;/pre&gt;  &lt;/p&gt;  &lt;p&gt;So yea it&amp;#39;s ugly, but it seems to work. Please give me a better way to perfom this, I will be glad.&lt;/p&gt;  &lt;p&gt;&amp;nbsp;&lt;/p&gt;  &lt;p&gt;Regards.&lt;/p&gt;</description></item></channel></rss>