Is the relationship from a Slide Part to a Custom XML Part not an explicit relationship instead of an...











up vote
2
down vote

favorite












If I want to associate a Custom XML Part to a Slide Part, the way I know of, is to add a custData element inside the Slide Part, and reference the relationship id of the Custom XML Part in the id attribute.



<p:custDataLst>
<p:custData r:id="rId1" />
</p:custDataLst>


As I understand it, this is an explicit relationship, because the reference is via the relationship id.



However, ECMA-376 Part 1, fifth edition (Latest version currently), says that a Slide Part is only permitted to have an implicit relationship to a Custom XML Part (Section 13.3.8).



That doesn't really make sense to me. In practice, I see an explicit relationship, while the specification only allows for an implicit one.



This is also how PowerPoint do it if I use the VSTO object model. If I create a completely fresh VSTO project, and edit the startup method to be like this:



private void ThisAddIn_Startup(object sender, System.EventArgs e)
{
Application.AfterNewPresentation += pres =>
{
var firstSlide = pres.Slides[1];
var customXmlPart = firstSlide.CustomerData.Add();
customXmlPart.LoadXML("<test></test>");
};
}


Then save the presentation and look at the package structure, PowerPoint did the exact same thing: Added a custData element to the slide, referencing the custom XML part using the relationship id. I.e. an explicit relationship.



I'm confident that the specification is correct, so what am I missing?










share|improve this question


























    up vote
    2
    down vote

    favorite












    If I want to associate a Custom XML Part to a Slide Part, the way I know of, is to add a custData element inside the Slide Part, and reference the relationship id of the Custom XML Part in the id attribute.



    <p:custDataLst>
    <p:custData r:id="rId1" />
    </p:custDataLst>


    As I understand it, this is an explicit relationship, because the reference is via the relationship id.



    However, ECMA-376 Part 1, fifth edition (Latest version currently), says that a Slide Part is only permitted to have an implicit relationship to a Custom XML Part (Section 13.3.8).



    That doesn't really make sense to me. In practice, I see an explicit relationship, while the specification only allows for an implicit one.



    This is also how PowerPoint do it if I use the VSTO object model. If I create a completely fresh VSTO project, and edit the startup method to be like this:



    private void ThisAddIn_Startup(object sender, System.EventArgs e)
    {
    Application.AfterNewPresentation += pres =>
    {
    var firstSlide = pres.Slides[1];
    var customXmlPart = firstSlide.CustomerData.Add();
    customXmlPart.LoadXML("<test></test>");
    };
    }


    Then save the presentation and look at the package structure, PowerPoint did the exact same thing: Added a custData element to the slide, referencing the custom XML part using the relationship id. I.e. an explicit relationship.



    I'm confident that the specification is correct, so what am I missing?










    share|improve this question
























      up vote
      2
      down vote

      favorite









      up vote
      2
      down vote

      favorite











      If I want to associate a Custom XML Part to a Slide Part, the way I know of, is to add a custData element inside the Slide Part, and reference the relationship id of the Custom XML Part in the id attribute.



      <p:custDataLst>
      <p:custData r:id="rId1" />
      </p:custDataLst>


      As I understand it, this is an explicit relationship, because the reference is via the relationship id.



      However, ECMA-376 Part 1, fifth edition (Latest version currently), says that a Slide Part is only permitted to have an implicit relationship to a Custom XML Part (Section 13.3.8).



      That doesn't really make sense to me. In practice, I see an explicit relationship, while the specification only allows for an implicit one.



      This is also how PowerPoint do it if I use the VSTO object model. If I create a completely fresh VSTO project, and edit the startup method to be like this:



      private void ThisAddIn_Startup(object sender, System.EventArgs e)
      {
      Application.AfterNewPresentation += pres =>
      {
      var firstSlide = pres.Slides[1];
      var customXmlPart = firstSlide.CustomerData.Add();
      customXmlPart.LoadXML("<test></test>");
      };
      }


      Then save the presentation and look at the package structure, PowerPoint did the exact same thing: Added a custData element to the slide, referencing the custom XML part using the relationship id. I.e. an explicit relationship.



      I'm confident that the specification is correct, so what am I missing?










      share|improve this question













      If I want to associate a Custom XML Part to a Slide Part, the way I know of, is to add a custData element inside the Slide Part, and reference the relationship id of the Custom XML Part in the id attribute.



      <p:custDataLst>
      <p:custData r:id="rId1" />
      </p:custDataLst>


      As I understand it, this is an explicit relationship, because the reference is via the relationship id.



      However, ECMA-376 Part 1, fifth edition (Latest version currently), says that a Slide Part is only permitted to have an implicit relationship to a Custom XML Part (Section 13.3.8).



      That doesn't really make sense to me. In practice, I see an explicit relationship, while the specification only allows for an implicit one.



      This is also how PowerPoint do it if I use the VSTO object model. If I create a completely fresh VSTO project, and edit the startup method to be like this:



      private void ThisAddIn_Startup(object sender, System.EventArgs e)
      {
      Application.AfterNewPresentation += pres =>
      {
      var firstSlide = pres.Slides[1];
      var customXmlPart = firstSlide.CustomerData.Add();
      customXmlPart.LoadXML("<test></test>");
      };
      }


      Then save the presentation and look at the package structure, PowerPoint did the exact same thing: Added a custData element to the slide, referencing the custom XML part using the relationship id. I.e. an explicit relationship.



      I'm confident that the specification is correct, so what am I missing?







      vsto powerpoint openxml






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Nov 6 at 19:54









      René

      7,69643247




      7,69643247
























          1 Answer
          1






          active

          oldest

          votes

















          up vote
          1
          down vote













          Okay, so it turns out that Office knowingly doesn't follow the specification to the letter. Luckily, Microsoft actually documents where they diverge from the standard. This documentation can be found at the Open Specifications website on MSDN. Diving into the documentation here, I found the page Word, Excel, and PowerPoint Standards Support, which has quite a few PDF documents that documents how the standard is implemented in Word, PowerPoint and Excel. Diving further into [MS-OE376]: Office Implementation Information for ECMA-376 Standards Support, section 2.1.23.e states:




          The standard states that the Presentation part is permitted to have an implicit relationship to a Custom XML Data Storage part.



          Office also allows for an explicit relationship between the Presentation part and a Custom XML Data Storage part.




          The PDF document doesn't say anything about this for slides, but now I'm no longer unsure if I was interpreting the standard incorrectly or if PowerPoint just didn't follow the standard. It's pretty clear that PowerPoint in a lot of cases doesn't follow the standard, so the specific case I have with an explicit relationship between a Slide Part and a Custom XML Data Storage Part is probably just another case where PowerPoint doesn't follow the standard.






          share|improve this answer





















            Your Answer






            StackExchange.ifUsing("editor", function () {
            StackExchange.using("externalEditor", function () {
            StackExchange.using("snippets", function () {
            StackExchange.snippets.init();
            });
            });
            }, "code-snippets");

            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "1"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














             

            draft saved


            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53179056%2fis-the-relationship-from-a-slide-part-to-a-custom-xml-part-not-an-explicit-relat%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            1
            down vote













            Okay, so it turns out that Office knowingly doesn't follow the specification to the letter. Luckily, Microsoft actually documents where they diverge from the standard. This documentation can be found at the Open Specifications website on MSDN. Diving into the documentation here, I found the page Word, Excel, and PowerPoint Standards Support, which has quite a few PDF documents that documents how the standard is implemented in Word, PowerPoint and Excel. Diving further into [MS-OE376]: Office Implementation Information for ECMA-376 Standards Support, section 2.1.23.e states:




            The standard states that the Presentation part is permitted to have an implicit relationship to a Custom XML Data Storage part.



            Office also allows for an explicit relationship between the Presentation part and a Custom XML Data Storage part.




            The PDF document doesn't say anything about this for slides, but now I'm no longer unsure if I was interpreting the standard incorrectly or if PowerPoint just didn't follow the standard. It's pretty clear that PowerPoint in a lot of cases doesn't follow the standard, so the specific case I have with an explicit relationship between a Slide Part and a Custom XML Data Storage Part is probably just another case where PowerPoint doesn't follow the standard.






            share|improve this answer

























              up vote
              1
              down vote













              Okay, so it turns out that Office knowingly doesn't follow the specification to the letter. Luckily, Microsoft actually documents where they diverge from the standard. This documentation can be found at the Open Specifications website on MSDN. Diving into the documentation here, I found the page Word, Excel, and PowerPoint Standards Support, which has quite a few PDF documents that documents how the standard is implemented in Word, PowerPoint and Excel. Diving further into [MS-OE376]: Office Implementation Information for ECMA-376 Standards Support, section 2.1.23.e states:




              The standard states that the Presentation part is permitted to have an implicit relationship to a Custom XML Data Storage part.



              Office also allows for an explicit relationship between the Presentation part and a Custom XML Data Storage part.




              The PDF document doesn't say anything about this for slides, but now I'm no longer unsure if I was interpreting the standard incorrectly or if PowerPoint just didn't follow the standard. It's pretty clear that PowerPoint in a lot of cases doesn't follow the standard, so the specific case I have with an explicit relationship between a Slide Part and a Custom XML Data Storage Part is probably just another case where PowerPoint doesn't follow the standard.






              share|improve this answer























                up vote
                1
                down vote










                up vote
                1
                down vote









                Okay, so it turns out that Office knowingly doesn't follow the specification to the letter. Luckily, Microsoft actually documents where they diverge from the standard. This documentation can be found at the Open Specifications website on MSDN. Diving into the documentation here, I found the page Word, Excel, and PowerPoint Standards Support, which has quite a few PDF documents that documents how the standard is implemented in Word, PowerPoint and Excel. Diving further into [MS-OE376]: Office Implementation Information for ECMA-376 Standards Support, section 2.1.23.e states:




                The standard states that the Presentation part is permitted to have an implicit relationship to a Custom XML Data Storage part.



                Office also allows for an explicit relationship between the Presentation part and a Custom XML Data Storage part.




                The PDF document doesn't say anything about this for slides, but now I'm no longer unsure if I was interpreting the standard incorrectly or if PowerPoint just didn't follow the standard. It's pretty clear that PowerPoint in a lot of cases doesn't follow the standard, so the specific case I have with an explicit relationship between a Slide Part and a Custom XML Data Storage Part is probably just another case where PowerPoint doesn't follow the standard.






                share|improve this answer












                Okay, so it turns out that Office knowingly doesn't follow the specification to the letter. Luckily, Microsoft actually documents where they diverge from the standard. This documentation can be found at the Open Specifications website on MSDN. Diving into the documentation here, I found the page Word, Excel, and PowerPoint Standards Support, which has quite a few PDF documents that documents how the standard is implemented in Word, PowerPoint and Excel. Diving further into [MS-OE376]: Office Implementation Information for ECMA-376 Standards Support, section 2.1.23.e states:




                The standard states that the Presentation part is permitted to have an implicit relationship to a Custom XML Data Storage part.



                Office also allows for an explicit relationship between the Presentation part and a Custom XML Data Storage part.




                The PDF document doesn't say anything about this for slides, but now I'm no longer unsure if I was interpreting the standard incorrectly or if PowerPoint just didn't follow the standard. It's pretty clear that PowerPoint in a lot of cases doesn't follow the standard, so the specific case I have with an explicit relationship between a Slide Part and a Custom XML Data Storage Part is probably just another case where PowerPoint doesn't follow the standard.







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Nov 9 at 10:57









                René

                7,69643247




                7,69643247






























                     

                    draft saved


                    draft discarded



















































                     


                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53179056%2fis-the-relationship-from-a-slide-part-to-a-custom-xml-part-not-an-explicit-relat%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Schultheiß

                    Verwaltungsgliederung Dänemarks

                    Liste der Kulturdenkmale in Wilsdruff