Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    [bug] loadUI tag throws an error

    SmartClient Version: 8.0/PowerEdition Deployment (built 2011-01-21)

    developer console log:
    12:50:45.796:WARN:Log:Server-generated XML parsing error: XML parser fatal error: file 'F:\iscSDK\tools\visualBuilder\workspace\iscRuntime\WebContent\shared\ui\prova.ui.xml' line 17: org.xml.sax.SAXParseException: The markup in the document following the root element must be well-formed.

    Code:
    <%@ page contentType="text/html; charset=UTF-8"%>
    <%@ taglib uri="/WEB-INF/iscTaglib.xml" prefix="isomorphic" %>
    <HTML><HEAD><TITLE>prova</TITLE>
    <isomorphic:loadISC skin="Graphite"/>
    </HEAD><BODY>
    <SCRIPT>
    isc.Page.setAppImgDir("../graphics/");
    <isomorphic:loadUI name="prova" />
    </SCRIPT>
    </BODY></HTML>
    prova.ui.xml:
    Code:
    <TabSet ID="TabSet1" autoDraw="false">
        <tabs>
            <Tab>
                <title>Tab2</title>
                <ID>Tab2</ID>
            </Tab>
            <Tab>
                <title>Tab3</title>
                <ID>Tab3</ID>
            </Tab>
        </tabs>
        <destroyPanes>false</destroyPanes>
    </TabSet>
    
    
    <VLayout ID="VLayout1" autoDraw="true">
        <members><Canvas ref="TabSet1"/>
        </members>
    </VLayout>
    If there is a single object, then it renders correctly:
    Code:
    <TabSet ID="TabSet1" autoDraw="true">
        <tabs>
            <Tab>
                <title>Tab2</title>
                <ID>Tab2</ID>
            </Tab>
            <Tab>
                <title>Tab3</title>
                <ID>Tab3</ID>
            </Tab>
        </tabs>
        <destroyPanes>false</destroyPanes>
    </TabSet>

    #2
    Multiple top-level elements in an XML file is considered invalid XML. You need to wrap the entire contents in <isomorphicXML> to avoid this.

    Comment


      #3
      Thanks.

      does this mean that it's not possible to load the ui XML file saved by visual builder without first adding those <isomorphicXML> tags?

      or there's an option to load it? Otherwise it's a bit annoying...

      Comment


        #4
        What you should see is that there's a warning in the logs, then it automatically wraps the file and proceeds.

        Comment


          #5
          nope, I got a blank page, the HTML source of the page contains a warning which tells of a server fatal error:

          Log.logWarn("Server-generated XML parsing error: XML parser fatal error: file 'F:\\iscSDK\\tools\\visualBuilder\\workspace\\shared\\ui\\demo.ui.xml' line 6: org.xml.sax.SAXParseException: The markup in the document following the root element must be well-formed.")

          and no javascript code got included.
          Last edited by claudiobosticco; 6 Jun 2011, 04:43.

          Comment


            #6
            I've just tried SmartClient_SC_SNAPSHOT-2011-06-05 and I have the same problem.

            Comment


              #7
              We're showing this as working. Can you put together a test case?

              Comment


                #8
                I stand corrected!
                the SNAPSHOT-2011-06-05 is working.

                Comment

                Working...
                X