advanced-tables-obsidian icon indicating copy to clipboard operation
advanced-tables-obsidian copied to clipboard

Autonumbering of rows

Open richardlm opened this issue 2 years ago • 1 comments

Issue I often want the content rows of a table to be numbered, 1...n. At the moment I have to do this manually, which is a significant manual overhead.

Describe the solution you'd like For all content rows to be numbered automatically.

Describe alternatives you've considered This can be achieved if one uses the Yin & Yang theme and enters cssclass: numbertable in YAML frontmatter, but I am not aware that other themes support this.

Additional context

richardlm avatar Jan 26 '22 14:01 richardlm

@richardlm You could try this not to do it manually:

<!-- TBLFM: @I$<=1 -->
<!-- TBLFM: @3$<..@>$<=(@-1+1) -->

First column in first data row is assigned a number of 1. Second formula adds +1 to the appropriate cell from the row above till the end. Change it a bit if you have totals or any other additional rows at the end of a table.

naabtog avatar Nov 02 '22 19:11 naabtog