# Node-red-node-ui-table pdf download is missing the Group count

**URL:** https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015
**Category:** Dashboard
**Tags:** ui-widgets
**Created:** [14 October 2022 08:10 UTC](https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015 "2022-10-14T08:10:24Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![akd02](https://avatars.discourse-cdn.com/v4/letter/a/5e9695/32.png) [@akd02](https://discourse.nodered.org/u/akd02)
#### Post date: [14 October 2022 08:10 UTC](https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015/1 "2022-10-14T08:10:24Z")

</div>

Hello Everyone,

I am using the ui\_table node on a dashboard.

all works well, including exporting / downloading a PDF file from the data shown in the table.

On the dashbiard itself i can see the count of objects / rows in a group, see attached example "Dept. 11 has 13 items"  
 ![table in UI dashboard](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/3/e/3efc180e60b410d048007152f63c94c95875d4a2.png)

however when i export the PDF i am missing the count "13 in this case" see attached picture from the PDF export.

![PDF table](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/e/b/ebc81c48c90264e7749dba58919e179ae2c94aa7.png)

The msg object i am injecting into the UI\_table node inorder to export the PDF looks like this:

```auto
{"payload":{"command":"download","arguments":["pdf","fileName.pdf",{"orientation":"landscape","title":"documentTitle","jsPDF":{"compress":true},"autoTable":{"theme":"striped","headStyles":{"font":"helvetica","fontStyle":"bold","textColor":"#000000","fontSize":12,"fillColor":[0,121,147]},"bodyStyles":{"font":"helvetica","textColor":"#000000","fontSize":10}}}],"returnPromise":false},"event":{"clientX":964,"clientY":150,"bbox":[849,174,1059,126]},"socketid":"jjTH9b_VPet5k1YlAAEv","_msgid":"89c365624f128928"}

```

any tips on how to make the group count appear on the PDF file?

---

<div class="post-metadata">

### Author: ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)
#### Post date: [14 October 2022 09:52 UTC](https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015/2 "2022-10-14T09:52:26Z")

</div>

Without the ui-table node with your settings, that data returns nothing.

Please provide a flow showing the problem.

---

<div class="post-metadata">

### Author: ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)
#### Post date: [14 October 2022 10:45 UTC](https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015/4 "2022-10-14T10:45:13Z")

</div>

At the moment, I am unable to export the table as a PDF. I have no problem with a CSV export. I will look at this more but I'm about to be distracted for most of the rest of the day.

---

<div class="post-metadata">

### Author: ![akd02](https://avatars.discourse-cdn.com/v4/letter/a/5e9695/32.png) [@akd02](https://discourse.nodered.org/u/akd02)
#### Post date: [14 October 2022 11:45 UTC](https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015/5 "2022-10-14T11:45:52Z")

</div>

Yes, i know why pdf export is not working for you... because of the misisng jsPDF Library and jsPDF-AutoTable scripts.

i have added them to a template node in this new Flow file.

[ui table with PDF export including library.json](https://discourse.nodered.org/uploads/short-url/42Jr9WD4yyXHwAwSxWLADZgkqD9.json) (9.3 KB)

Thanks a million!! appreciate your help

and if you suggetsion would also include not only how to add the group count to the PDF but also to an CSV / XLS export that would also be awsome!!!!

---

<div class="post-metadata">

### Author: ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)
#### Post date: [14 October 2022 13:20 UTC](https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015/6 "2022-10-14T13:20:24Z")

</div>

(during a few minute break)

1. I had installed those libraries but even with your new flow, PDF doesn't export

1. If you go to the [tabulator site](http://tabulator.info/docs/5.4/download#main-contents) you will see:

## [CSV Download](http://tabulator.info/docs/5.4/download#csv)

**Config Options**  
The CSV downloader does not support grouped column headers, row groups or column calculations, because of the limited way to representing these in CSV data

What device are you running NR on and are you accessing the dashboard on the same computer or another one?

---

<div class="post-metadata">

### Author: ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)
#### Post date: [14 October 2022 23:28 UTC](https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015/7 "2022-10-14T23:28:59Z")

</div>

Ok, I've spent a bunch of time and I can not get the PDF to download. It keep getting an  
`Uncaught ReferenceError: jsPDF is not defined`  
error even after installing the node.

This is beyond my knowledge set, hopefully someone else will jump in to help.

---

<div class="post-metadata">

### Author: ![akd02](https://avatars.discourse-cdn.com/v4/letter/a/5e9695/32.png) [@akd02](https://discourse.nodered.org/u/akd02)
#### Post date: [18 October 2022 07:47 UTC](https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015/8 "2022-10-18T07:47:12Z")

</div>

Appreciate your time either way 🙂

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [17 November 2022 07:47 UTC](https://discourse.nodered.org/t/node-red-node-ui-table-pdf-download-is-missing-the-group-count/69015/9 "2022-11-17T07:47:16Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
