Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Description

Excerpt

When editing the Andorid the Mobile WMS configuration file, you MUST enable schema validation for your editor.

This guide explains how to enable schema validation and code completion in Visual Studio or VS-Code.

Overview

Table of Contents
maxLevel2
indent1
excludeOverview
printablefalse

Visual Studio

You only have to set one setting, to get get Schema support


Go to: Tools > Options > Text Editor > XML > Miscellaneous

and enable Automatically download DTDs and Shemas 


Visual Studio Code

It requires two extensions and a java library downloaded.

Java

Download Java here.
Extract the downloaded zip file to e.g. C:\Program Files\Java\jdk-12.0.2

Install and configure Visual Studio Code

Download and install Visual Studio Code (VS Code) here.
Install the two extensions "XML" and "Language Support for Java(TM) by Red Hat" in VS Code.
Press Ctrl + Shift + X to enter the extensions section, and search in the top.

Configure VS Code

Open the properties json file by pressing Ctrl + Shift + P.
Write "Open Settings" and select "Preferences: Open Settings (JSON)".

Add the following lines to the JSON file. Make sure that the java.home property references the location where the java library was extracted to.

Code Block
{
   "workbench.startupEditor": "newUntitledFile",
   "java.home": "C:\\Program Files\\Java\\jdk-12.0.2",
   "files.associations": {
      "application*.cfg": "xml",
      "start*.cfg": "xml"
   },
   "xml.fileAssociations": [
      {
         "systemId": "http://schemas.taskletfactory.com/MobileWMS/Application.xsd",
         "pattern": "application.cfg"
      },
      {
         "systemId": "http://schemas.taskletfactory.com/MobileWMS/Start.xsd",
         "pattern": "start.cfg"
      }
   ]
}

Configuration files

Make sure that application.cfg and start.cfg contains the following headers respectively.

Code Block
languagexml
titleapplication.cfg
<application xmlns="http://schemas.taskletfactory.com/MobileWMS/Application"
			 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
			 xsi:schemaLocation="http://schemas.taskletfactory.com/MobileWMS/Application http://schemas.taskletfactory.com/MobileWMS/Application.xsd">


Code Block
languagexml
titlestart.cfg
<start xmlns="http://schemas.taskletfactory.com/MobileWMS/Start"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	   xsi:schemaLocation="http://schemas.taskletfactory.com/MobileWMS/Start http://schemas.taskletfactory.com/MobileWMS/Start.xsd"
	   language="en"
	   screenOrientation="Portrait">

Update schema files

As the schema files are downloaded on first use, they may need to be updated from time to time, as more features are added in the configuration.
This is done by deleting the existing schema files in the following directory.

Code Block
C:\Users\<YourUsernameHere>\.lemminx\cache\http\schemas.taskletfactory.com\MobileWMS




Explore the Mobile WMS App

Page Tree
rootMobile WMS App