Skip to content

Empty XML Element tag issue #5

@pbrooks100

Description

@pbrooks100

I'm using JKI-EasyXML to write test results for a third party.
They claim that the empty elements contained in the file are not compliant; the element tag should have a space between the name and the forward slash. Their parser rejects the JKI-EasyXML output.

https://www.w3schools.com/xml/xml_elements.asp

There are two ways to indicate an empty element;

<element></element> or <element />

Example of JKI-EasyXML output:

<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<TESTRESULTS>
  <MODEL>UNKNOWN</MODEL>
  <PC>Station 1</PC>
  <SERIALNUMBER>BR549</SERIALNUMBER>
  <PN/>
  <MAC>00:11:22:33:44:55</MAC>
  <HWID/>
  <R/>
  <PASSFAIL>P</PASSFAIL>
  <FAILCODE/>
</TESTRESULTS>

Expected XML:

<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<TESTRESULTS>
  <MODEL>UNKNOWN</MODEL>
  <PC>Station 1</PC>
  <SERIALNUMBER>BR549</SERIALNUMBER>
  <PN />
  <MAC>00:11:22:33:44:55</MAC>
  <HWID />
  <R />
  <PASSFAIL>P</PASSFAIL>
  <FAILCODE />
</TESTRESULTS>

I've narrowed the issue down to

 'JKI_EasyXML.llb\XML Build Entity__JKI EasyXML.vi'

but due to the recursive design of the calling VI

 'JKI_EasyXML.llb\Variant to XML - core - __JKI EasyXML.vi' 

I am hesitant to make any quick changes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions