Count of rows in a DITA table
Post here questions and problems related to editing and publishing DITA content.
-
- Posts: 316
- Joined: Wed Jun 17, 2015 10:19 am
Count of rows in a DITA table
Post by ann.jensen »
Hi,
Is there any way of identifying the number of rows in a DITA table through Oxygen XML Author?
Thanks in advance,
Ann
Is there any way of identifying the number of rows in a DITA table through Oxygen XML Author?
Thanks in advance,
Ann
-
- Posts: 9443
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Count of rows in a DITA table
Hi Ann,
Maybe if the caret is inside the table, you could run an XPath using our XPath toolbar with something like:
Regards,
Radu
Maybe if the caret is inside the table, you could run an XPath using our XPath toolbar with something like:
Code: Select all
ancestor-or-self::table/count(.//row)
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 316
- Joined: Wed Jun 17, 2015 10:19 am
Re: Count of rows in a DITA table
Post by ann.jensen »
Hi Radu,
That worked perfectly
thanks again,
Ann
That worked perfectly

thanks again,
Ann
-
- Posts: 316
- Joined: Wed Jun 17, 2015 10:19 am
Re: Count of rows in a DITA table
Post by ann.jensen »
Is it possible to use something like CSS in Oxygen Author to automatically include this value in the DITA table title.
Regards,
Ann
Regards,
Ann
-
- Posts: 9443
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Count of rows in a DITA table
Hi Ann,
Sure, you need to use a CSS selector like:
The oxy_xpath may induce editing performance problems though so please do not use it if you have very large topics.
More about using your custom editing CSS with DITA:
http://blog.oxygenxml.com/2016/10/custo ... iting.html
Regards,
Radu
Sure, you need to use a CSS selector like:
Code: Select all
*[class~="topic/table"] > *[class~="topic/title"]:after{
content: " [Number of rows]:" oxy_xpath('ancestor::table/count(.//row)');
}
More about using your custom editing CSS with DITA:
http://blog.oxygenxml.com/2016/10/custo ... iting.html
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 316
- Joined: Wed Jun 17, 2015 10:19 am
Return to “DITA (Editing and Publishing DITA Content)”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service