Page 1 of 1

Getting debugging view to show context node?

Posted: Fri Mar 29, 2019 2:50 am
by RBVanDyke
For oXygen 21.

As part of learning XSLT I'm doing examples from a book. But oXygen XML, debug view, Nodes/Values Set panel isn't displaying the transform's context node.

Here's the target XML:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<appetizers title="Work up an Appetite">
<dish id="1" price="8.95">Crab Cakes</dish>
<dish id="2" price="9.95">Jumbo Prawns</dish>
<dish id="3" price="10.95">Smoked Salmon and Avocado Quesadilla</dish>
<dish id="4" price="6.95">Caesar Salad</dish>
<entrees title="Chow Time!">
<dish id="5" price="19.95">Grilled Salmon</dish>
<dish id="6" price="17.95">Seafood Pasta</dish>
<dish id="7" price="16.95">Linguini al Pesto</dish>
<dish id="8" price="18.95">Rack of Lamb</dish>
<dish id="9" price="16.95">Ribs and Wings</dish>
<desserts title="To Top It Off">
<dish id="10" price="6.95">Dame Blanche</dish>
<dish id="11" price="5.95">Chocolat Mousse</dish>
<dish id="12" price="6.95">Banana Split</dish>
Here's the XSLT (which transforms as expected):

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"

<xsl:template match="/menu/appetizers"> -<xsl:value-of
select="dish[1]/ancestor::*[1]/@title"/> -<xsl:value-of

<xsl:template match="/menu/entrees"/>
<xsl:template match="/menu/desserts"/>

I've read the HELP topic Tree View for Presenting Node Set Values.

But for whatever reason -- probably because I don't know what I'm doing -- NOTHING appears in the Nodes/Values Set panel.

As part of learning and future debugging, how can I get oXygen XML Editor to tell me what the current context node[\i] is?

Thanks as always,

Re: Getting debugging view to show context node?

Posted: Fri Mar 29, 2019 10:09 am
by adrian

If you are looking for the context node during debugging, you should try the Context view.
The Nodes/Values Set view, located in the right side panel, is meant to show a detailed (tree) view of what is selected in the left side panel from the XWatch or Variables views.

Not sure why the "the current context node value" is mentioned explicitly on the web site info page that you found. I guess you could use . (current context) in XWatch and when you select it you would actually see the current context node in the Nodes/Values Set view. Other than that the Nodes/Values Set has nothing to do with the context node.
I've logged an issue to correct the misleading web page info.


Re: Getting debugging view to show context node?

Posted: Sat Mar 30, 2019 12:21 am
by RBVanDyke
Thanks as always, Adrian.

Good to know my question will contribute to tidying up the HELP page a bit, too.

Cheers, Riley SFO