title: SAPUI5 - add Fragment in SimpleForm
body: <p>i have a problem with adding an fragment to an SimpleForm in SAPUI5. I have an SimpleForm and want to add content in the form with fragments. The result should look like this:
  <a href="https://i.stack.imgur.com/LsZzl.png" rel="nofollow noreferrer">what i want done</a></p>
  
  <p>my fragment:</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;core:FragmentDefinition 
   xmlns="sap.m" 
   xmlns:core="sap.ui.core" 
   xmlns:mvc="sap.ui.core.mvc" 
   xmlns:html="http://www.w3.org/1999/xhtml"
   xmlns:l="sap.ui.layout" 
   xmlns:f="sap.ui.layout.form"
   xmlns:tnt="sap.tnt" 
   xmlns:custom="http://schemas.sap.com/sapui5/extension/sap.ui.core.CustomData/1"&gt;
  
    &lt;core:Title text="{i18n&gt;beauskunftung.suche.address}"/&gt;
    &lt;Label text="{i18n&gt;beauskunftung.suche.streetNo}"/&gt;
    &lt;Input editable="false" fieldGroupIds="Address" value="{AddressStreet}" id="inputStreetID"&gt;&lt;/Input&gt;
    &lt;Input editable="false" fieldGroupIds="Address" value="{AddressStreetNumber}" id="inputNumberID"&gt;
     &lt;layoutData&gt;
      &lt;l:GridData span="L3 M3 S4"/&gt;
     &lt;/layoutData&gt;
    &lt;/Input&gt;
    &lt;Label text="{i18n&gt;beauskunftung.suche.zipCity}"/&gt;
    &lt;Input editable="false" fieldGroupIds="Address" value="{AddressZipCode}" id="inputZipID"&gt;
     &lt;layoutData&gt;
      &lt;l:GridData span="L3 M3 S4"/&gt;
     &lt;/layoutData&gt;
    &lt;/Input&gt;
    &lt;Input editable="false" fieldGroupIds="Address" value="{AddressCity}" id="inputCityID"/&gt;
  
  &lt;/core:FragmentDefinition&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>if i add the fragment with javacript</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code> var oFragment = sap.ui.xmlfragment("testistest", "com.natuvion.ddi.fragments.select.address");
    var oLayout = this.getView().byId("AddressIDandSoOn");
    oLayout.insertContent(oFragment, -1);</code></pre>
  </div>
  </div>
  </p>
  
  <p>i get the following error:</p>
  
  <p>Uncaught (in promise) Error: "Element sap.ui.core.Title#__title0,Element sap.m.Label#__label0,Element sap.m.Input#testistest--inputStreetID,Element sap.m.Input#testistest--inputNumberID,Element sap.m.Label#__label1,Element sap.m.Input#testistest--inputZipID,Element sap.m.Input#testistest--inputCityID" is not valid for aggregation "content" of Element sap.ui.layout.form.SimpleForm#__xmlview1--AddressIDandSoOn</p>
  
  <p>I think the problem is that the add method can just add one element (if I have just a label in the fragment it works!). I looked for some element which should contains all the elements from the fragment but I didn't find one. If I add the fragment via XML on the page </p>
  
  <pre><code>&lt;core:Fragment id="addressFragment1" 
  fragmentName="com.natuvion.ddi.fragments.select.address" type="XML"&gt; 
  &lt;/core:Fragment&gt;
  </code></pre>
  
  <p>it works. At this point I have no idea how to add fragments inside an SimpleForm. I need the dynamic generation of the elements, as I have to add this depending on the given data, possibly also several times</p>
  
  <p>My Question:
   - How can i add an Fragment to an SimpleForm?</p>