Include Index Column Detail In Table Overview Page

The Table Overview page generated by Document! X includes a table detailing the indexes defined for the Table. It is possible, by creating and modifying a custom Template, to include a new column in the summary table detailing the columns for each index.

Create a custom Database Documentation template

If you haven't already created a custom Template, create one (for Database documentation). Base your custom template on the standard 2012 Style Database Documentation Template. You can do this from the Custom Templates page in Options (select Options from the Tools Ribbon Tab).

This movie takes you through the process of creating a custom Template:

Add some new Scraps to the custom Template for the index column list

Add the following scraps to the custom Template (scrap name in bold, content below):





Modify the Index List Scrap to include a new column

We will now use the new scraps we created above in a FilteredItemList Metadata Element. The new Metadata Element will be placed in a new Table column in the Index List Scrap.

Modify the scraps below as follows (scrap name in bold, content highlighted):


<tr><td class=%%IsNew:Format=LinkCell IsNew,BlankFormat=LinkCell%%><A HREF="%%itemqualifiedname%%.html">%%itemname%%</A></td><td class="DescriptionCell">%%strippedDescription:BlankFormat=&nbsp;%%</td><td
<td Class="Centered">%%IndexProperty:Name=PrimaryKey,Format="<img src=dbimages/tick.gif>",BlankFormat=&nbsp;%%</td><td Class="Centered">%%IndexProperty:Name=Unique,Format="<img src=dbimages/tick.gif>",BlankFormat=&nbsp;%%</td></tr>


<table class="FilteredItemListTable"><tr><th>%%TypeName%%</th><th>Description</th><th>Columns</th><th>PrimaryKey_Short</th><th>Unique_Short</th></tr>

Use your custom Template in your project

Open your Project in Document! X and on the Templates page in the Build Profile Editor choose your custom Template.


Your output (and when editing or previewing in the Content File Editor) will now contain column details in the Index table, as illustrated below:



Have more questions? Submit a request


Please sign in to leave a comment.