swirl Guide to OmniMark 5   OmniMark home
docs home 
IndexConceptsTasksSyntaxLibrariesOMX VariablesErrors
 
     
operator   number of current elements    

Return type: Integer
Returns:       

Number of opened elements.



Syntax
  number of current elements element-qualifier*


Purpose

The number of currently opened elements, including the currently opened element (if any), can be determined using number of current elements.

Similarly, the number of opened elements down to and including a specified opened element can be determined by adding an element qualifier to specify the element to be examined.

If number of current elements is followed by of and an element-qualifier, then that qualifier must identify a currently opened element. On the other hand, number of current elements can always be used without a qualifier. If there are no opened elements, then the number of current elements without a following element qualifier has a value of zero (0).

The following element rule uses number of current elements to show the depth of the current element in the overall element hierarchy:

  element #implied
     set depth to number of current elements
     output "Element %q is nested %d(depth) deep. %n"
     output "%c"

       
----  

Top [ INDEX ] [ CONCEPTS ] [ TASKS ] [ SYNTAX ] [ LIBRARIES ] [ OMX ] [ OMX ] [ ERRORS ]

Generated: August 11, 2000 at 3:07:36 pm
If you have any comments about this section of the documentation, send email to docerrors@omnimark.com

Copyright © OmniMark Technologies Corporation, 1988-2000.