The simplest way to start a debugging session is to start one from an XSLT, XQuery, or XML file. If the required associated file (see Table of associated files) has already been assigned to the active file, then the debugging session is started immediately. Otherwise you are prompted to select the required associated file. Since XQuery files neither require nor contain an XML file association, you can choose to be prompted for an optional XML file association each time you start an XQuery debugging session from an XQuery file, or to not be prompted.
Predefined associations are relevant only for XSLT debugging sessions, and refer to cases in which the associated file assignment is already present in the active file. To make an assignment in an XML or XSLT file, do the following:
•In XML/JSON files: Open the file, click XSL/XQuery | Assign XSL and select the XSLT file.
•In XSLT files: Open the file, click XSL/XQuery | Assign sample XML file, and select the XML file.
When you click XSL/XQuery | Start Debugger/Go, the debugging session is started directly, i.e. without you being prompted for any file to associate with the active file.
If no predefined association is present in the active file, you are prompted for an association. When you select XSL/XQuery | Start Debugger/Go, the following happens:
•For XML files: You are prompted to select an XSLT, XQuery, or XQuery Update file.
•For JSON files: You are prompted to select an XSLT, XQuery, or XQuery Update file
•For XSLT files: You are prompted to select an XML file.
•For XQuery files: You are given the option of selecting an XML file, which you can skip.
(The dialog shown in the screenshot appears when you start a debugging session from an XQuery file.)
After you select the required associated file or skip an optional association, the debugging session is started.
Alternative method of file association
In the Project Properties dialog, you can make predefined associations. Click Project | Project properties, and assign the required files by clicking the Use this XSL / Use this XML check box.
The XSLT and XQuery Debugger works only in Text View and Enhanced Grid View. If either your XML or XSLT file is open in some other view than Text or Grid View, or if an SPS file is associated with an XML file, the following dialog pops up when you start a debugging session involving one of these files.
Clicking OK causes the document to open in Text View. Note that XQuery files are always displayed in Text View.