POSXML - Language structure

  1. Organization and Structure
  2. Case sensitive
  3. Reserved characters
  4. Comments

The POSXML language follows the XML open standard. The XML standard is totally flexible and allows for rapid expansion. All formatting rules applied to XML persist in POSXML.

Organization and Structure

The POSXML language is organized and structured in the form of tags with levels and sublevels of commands that form the logical structure of the application. A tag can be identified when is located between the signs < (less than) and > (greater than), where they are opened and closed.

Case sensitive

The POSXML language is case sensitive, so there are differences between lowercase and uppercase words. You need to pay attention, especially when naming functions and variables.

Example:

<callfunction name="showmessage" />

<function name="showmessage">
  <display line="0" column="0" message=" Message 1" />
  <waitkey />
</function>

<function name="showmessage">
  <display line="0" column="0" message=" Message 2" />
  <waitkey />
</function>

Reserved characters

All reserved characters in XML are also reserved in POSXML and should be written in the correct way.

The following symbols on the left should be written as they appear on the right:

< &lt;
> &gt;
& &amp;
' &apos;
" &quot;

To display a message with the symbol < (less than), the code would be like:

<callfunction name="showmessage" />

<function name="showmessage">
  <display line="0" column="0" message="&lt; = lower" />
  <waitkey />
</function>

Comments

Comments blocks should be used with tags <!-- and --> as below:

<function name="showmessage">
  <!-- Display -->
  <display line="0" column="0" message="< = lower" />
  <waitkey />
</function>