# How insert in ui table an image in each row

**URL:** https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171
**Category:** Dashboard
**Tags:** node-red-dashboard
**Created:** [13 October 2021 16:35 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171 "2021-10-13T16:35:16Z")
**Posts on this page:** 13
**Page:** 1

<div class="post-metadata">

### Author: ![oualid](https://avatars.discourse-cdn.com/v4/letter/o/8dc957/32.png) [@oualid](https://discourse.nodered.org/u/oualid)
#### Post date: [13 October 2021 16:35 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/1 "2021-10-13T16:35:16Z")

</div>

hi,

i am trying to insert warning image in each row on my table.  
i used the blow code in msg.ui\_control but nothing diplay

```auto
{title:"Img", field:"img", "visible": true, "width":150,hight:20,align:"center",

                    "formatter": "function(cell, formatterParams, onRendered){return '<img width='20' height='20' alt='Image not found' src='/home/osboxes/node-red_1887/warning.jpg'/>''; }"

                 }

```

could help me  
thank you

---

<div class="post-metadata">

### Author: ![UnborN](https://avatars.discourse-cdn.com/v4/letter/u/4491bb/32.png) [@UnborN](https://discourse.nodered.org/u/UnborN)
#### Post date: [13 October 2021 19:37 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/2 "2021-10-13T19:37:21Z")

</div>

I dont think you need the ui\_control for that  
the ui\_table has a field, when configuring its columns, to set as an image

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/0/9/09ad44ff03237107e81bfc091b68394e222b211c.png)

**Example Flow :**

```auto
[{"id":"b7dff285.69049","type":"inject","z":"670e449e482aa4bb","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"[{\"Name\":\"<b>Yokoi</b>\",\"Age\":\"30\",\"Color\":\"lime\",\"Prog\":70,\"Star\":\"3\",\"image\":\"https://picsum.photos/id/234/50/50\"},{\"Name\":\"<i>DCJ</i>\",\"Age\":\"50\",\"Color\":\"dodgerblue\",\"Prog\":\"45\",\"Star\":2,\"Pass\":false,\"image\":\"https://picsum.photos/id/235/50/50\"},{\"Name\":\"Nick\",\"Age\":\"40\",\"Color\":\"darkred\",\"Prog\":95,\"Star\":\"5\",\"Pass\":true,\"image\":\"https://picsum.photos/id/236/50/50\"},{\"Name\":\"Ronin\",\"Age\":\"22\",\"Color\":\"dodgerblue\",\"Prog\":45,\"Star\":\"5\",\"Pass\":true,\"image\":\"https://picsum.photos/id/237/50/50\"}]","payloadType":"json","x":370,"y":660,"wires":[["7d48e13.90ee22"]]},{"id":"7d48e13.90ee22","type":"ui_table","z":"670e449e482aa4bb","group":"571a38b1.5e3638","name":"People","order":1,"width":"24","height":"10","columns":[{"field":"Name","title":"Who","width":"","align":"left","formatter":"html","formatterParams":{"target":"_blank"}},{"field":"Age","title":"Age","width":"","align":"center","formatter":"plaintext","formatterParams":{"target":"_blank"}},{"field":"Color","title":"","width":"","align":"left","formatter":"color","formatterParams":{"target":"_blank"}},{"field":"Star","title":"%","width":"","align":"left","formatter":"star","formatterParams":{"target":"_blank"}},{"field":"Pass","title":"","width":"","align":"center","formatter":"tickCross","formatterParams":{"target":"_blank"}},{"field":"Prog","title":"","width":"","align":"left","formatter":"progress","formatterParams":{"target":"_blank"}},{"field":"image","title":"Image","width":"","align":"center","formatter":"image","formatterParams":{"target":"_blank"}}],"outputs":0,"cts":false,"x":580,"y":660,"wires":[]},{"id":"571a38b1.5e3638","type":"ui_group","name":"Richer Table","tab":"29ec6908.552b36","order":1,"disp":true,"width":"24","collapse":false,"className":""},{"id":"29ec6908.552b36","type":"ui_tab","name":"Home","icon":"track_changes","order":1,"disabled":false,"hidden":false}]

```

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/7/87d86cc3b70ba99a77351b0328f22181a75296e5.png)

---

<div class="post-metadata">

### Author: ![Christian-Me](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/christian-me/32/10774_2.png) [@Christian-Me](https://discourse.nodered.org/u/Christian-Me)
#### Post date: [13 October 2021 20:45 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/3 "2021-10-13T20:45:30Z")

</div>

You might have to send the column definition to `msg.ui_control.tabulator.columns ` array.  
You can take a look into the provided examples how to format a ui\_control message.

Check the browser console for any error messages.

---

<div class="post-metadata">

### Author: ![oualid](https://avatars.discourse-cdn.com/v4/letter/o/8dc957/32.png) [@oualid](https://discourse.nodered.org/u/oualid)
#### Post date: [13 October 2021 20:59 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/4 "2021-10-13T20:59:25Z")

</div>

i already did this.  
please find all the flows that i used:

```auto
[
    {
        "id": "731cf73c8837e83f",
        "type": "tab",
        "label": "Flow 2",
        "disabled": false,
        "info": ""
    },
    {
        "id": "b2f7724575bccdb8",
        "type": "inject",
        "z": "731cf73c8837e83f",
        "name": "",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payloadType": "str",
        "x": 350,
        "y": 340,
        "wires": [
            [
                "3904341271fd2062",
                "e329b01d0f34ace7"
            ]
        ]
    },
    {
        "id": "8a799d2cd04946d3",
        "type": "debug",
        "z": "731cf73c8837e83f",
        "name": "",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 930,
        "y": 180,
        "wires": []
    },
    {
        "id": "8d06bd4ebc25bc6c",
        "type": "ui_table",
        "z": "731cf73c8837e83f",
        "group": "b070d416.db371",
        "name": "Thermostats",
        "order": 1,
        "width": "25",
        "height": "7",
        "columns": [],
        "outputs": 1,
        "cts": true,
        "x": 810,
        "y": 320,
        "wires": [
            []
        ]
    },
    {
        "id": "3904341271fd2062",
        "type": "function",
        "z": "731cf73c8837e83f",
        "name": "",
        "func": "msg.payload = [\n {\n \"name\":\"MEQ0451495\",\n \"room\":\"Bathroom\",\n \"TEMPERATURE\":22,\n \"ACTUAL TEMPERATURE\":21.8,\n \"VALVE STATE\":90,\n \"BATTERY STATE\":2.7\n },\n \n {\n \"name\":\"MEQ1875547\",\n \"room\":\"Living Room\",\n \"TEMPERATURE\":12,\n \"ACTUAL TEMPERATURE\":16.2,\n \"VALVE STATE\":10,\n \"BATTERY STATE\":2.7\n },\n \n {\n \"name\":\"MEQ1875515\",\n \"room\":\"Living Room2\",\n \"TEMPERATURE\":123,\n \"ACTUAL TEMPERATURE\":16.2,\n \"VALVE STATE\":35,\n \"BATTERY STATE\":2.7\n },\n \n {\n \"name\":\"MEQ1875515\",\n \"room\":\"Living Room2\",\n \"TEMPERATURE\":123,\n \"ACTUAL TEMPERATURE\":16.2,\n \"VALVE STATE\":100,\n \"BATTERY STATE\":2.7\n },\n {\n \"name\":\"MEQ1875515\",\n \"room\":\"Living Room2\",\n \"TEMPERATURE\":123,\n \"ACTUAL TEMPERATURE\":16.2,\n \"VALVE STATE\":70,\n \"BATTERY STATE\":2.7\n }\n]\n\n \nmsg.ui_control = {\n \"tabulator\":{\n columns:[\n {title:\"Name\", field:\"name\", width:200},\n {title:\"Room\", field:\"room\", widthGrow:3},\n {title:\"TEMPERATURE\", field:\"TEMPERATURE\", align:\"center\"},\n {title:\"ACTUAL TEMPERATURE\", field:\"ACTUAL TEMPERATURE\", sorter:\"number\", align:\"center\"},\n {\"formatterParams\":{\"target\":\"_blank\",\"min\":0,\"max\":99,\"color\":[\"green\",\"orange\",\"red\"],\n \"legend\":\"function (value) {return (value>0)? '&nbsp;&nbsp;'+value+' %' : '-';}\",\n \"legendColor\":\"#101010\",\"legendAlign\":\"center\"},\n \"title\":\"VALVE STATE\",\"field\":\"VALVE STATE\",\"formatter\":\"progress\",\"width\":100},\n {title:\"BATTERY STATE\", field:\"BATTERY STATE\", sorter:\"number\", align:\"center\"},\n {title:\"Action\", field:\"Action\", \"visible\": true, width:50,hight:20,\n \"formatter\": \"function(cell, formatterParams, onRendered){return '<button class=\\\"md-warn md-button \\\">Activate</button>'; }\"\n },\n {title:\"test\", field:\"test\", width:50,\n \"formatter\": \"function(cell, formatterParams, onRendered){return '<img width='30' height='30' alt='Image not found' src='data:image/png;base64,{{msg.imageSrc}}' />'; }\"\n }\n ]\n }\n}\n\n\n\nreturn msg;",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 590,
        "y": 320,
        "wires": [
            [
                "8d06bd4ebc25bc6c",
                "8a799d2cd04946d3"
            ]
        ]
    },
    {
        "id": "7466eb2b70a8cd74",
        "type": "inject",
        "z": "731cf73c8837e83f",
        "name": "reset table",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "[]",
        "payloadType": "json",
        "x": 580,
        "y": 200,
        "wires": [
            [
                "8d06bd4ebc25bc6c"
            ]
        ]
    },
    {
        "id": "77c863e6910aee6c",
        "type": "function",
        "z": "731cf73c8837e83f",
        "name": "msg.filename",
        "func": "msg.filename = \"C:\\\\Users\\\\Oualid\\\\Desktop\\\\warning.jpg\";\nreturn msg;\n \n\n",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 510,
        "y": 480,
        "wires": [
            [
                "a561775911f57a0e"
            ]
        ]
    },
    {
        "id": "ab7097a4786dee23",
        "type": "inject",
        "z": "731cf73c8837e83f",
        "name": "",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payloadType": "str",
        "x": 340,
        "y": 480,
        "wires": [
            [
                "77c863e6910aee6c"
            ]
        ]
    },
    {
        "id": "a561775911f57a0e",
        "type": "file in",
        "z": "731cf73c8837e83f",
        "name": "",
        "filename": "",
        "format": "",
        "chunk": false,
        "sendError": false,
        "encoding": "none",
        "allProps": false,
        "x": 690,
        "y": 480,
        "wires": [
            [
                "b44d73b1e1020dae"
            ]
        ]
    },
    {
        "id": "b44d73b1e1020dae",
        "type": "base64",
        "z": "731cf73c8837e83f",
        "name": "",
        "action": "str",
        "property": "payload",
        "x": 840,
        "y": 480,
        "wires": [
            [
                "7ecd396dc1ce9916"
            ]
        ]
    },
    {
        "id": "7ecd396dc1ce9916",
        "type": "function",
        "z": "731cf73c8837e83f",
        "name": "",
        "func": "msgPayload= msg.payload;\nmsg={imageSrc:msg.payload};\nreturn msg;",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 1000,
        "y": 480,
        "wires": [
            [
                "3904341271fd2062"
            ]
        ]
    },
    {
        "id": "e329b01d0f34ace7",
        "type": "change",
        "z": "731cf73c8837e83f",
        "name": "",
        "rules": [
            {
                "t": "set",
                "p": "payload",
                "pt": "msg",
                "to": "",
                "tot": "str"
            }
        ],
        "action": "",
        "property": "",
        "from": "",
        "to": "",
        "reg": false,
        "x": 450,
        "y": 420,
        "wires": [
            [
                "77c863e6910aee6c"
            ]
        ]
    },
    {
        "id": "b070d416.db371",
        "type": "ui_group",
        "name": "Table",
        "tab": "cd895ba5.a7168",
        "order": 1,
        "disp": true,
        "width": "25",
        "collapse": false
    },
    {
        "id": "cd895ba5.a7168",
        "type": "ui_tab",
        "name": "newTable",
        "icon": "dashboard",
        "disabled": false,
        "hidden": false
    }
]

```

thank you

---

<div class="post-metadata">

### Author: ![Christian-Me](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/christian-me/32/10774_2.png) [@Christian-Me](https://discourse.nodered.org/u/Christian-Me)
#### Post date: [13 October 2021 21:31 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/5 "2021-10-13T21:31:19Z")

</div>

Ok I see you like to send your image as a base64 encoded data. Sorry I can't help here as I don't have any experience with that line:

```auto
src='data:image/png;base64,{{msg.imageSrc}}'

```

but this can't work

```auto
msgPayload= msg.payload;
msg={imageSrc:msg.payload};
return msg;

```

a) there is something wrong in line 1.  
b) you have to set your call data via the complete array or commands. Then it will be passed to your formatter function by `cell.getValue()`. But without further tricks you have to send a copy of your file to every row in that column.

```auto
src='data:image/png;base64,{{'+cell.getValue()+'}}'

```

Tabulator and all callbacks don't have access to the msg object.

I think you can't you place your image where it could be accessed via http 🤷‍♂️? @UnborN solution would be the easiest. Or you use an icon (more efficient)  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/4/3/43907d441f82906d86715498ae3065b092ee18ac.png)  
perhaps scaled by 2x

---

<div class="post-metadata">

### Author: ![UnborN](https://avatars.discourse-cdn.com/v4/letter/u/4491bb/32.png) [@UnborN](https://discourse.nodered.org/u/UnborN)
#### Post date: [13 October 2021 22:33 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/6 "2021-10-13T22:33:44Z")

</div>

In Node-red `settings.js` file there is an option to serve files from a static folder.  
Un-comment `httpStatic` and point to a folder on your system to serve your own images

[Node-red Documentation - httpStatic](https://nodered.org/docs/user-guide/runtime/configuration)

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/c/1/c12fe33300fd3769b5ebb5689d0995c00cd33790.png)

The image (warning.jpg) can be then accessed from the url path  
`http://<node-red-ip>:1880/warning.jpg`

Then you can use the `msg.ui_control formatter` without the need for base64 that doesnt seem to be supported with Tabulator.

```auto
 {
      title: "test", field: "test", width: 50,
      "formatter": `function(cell, formatterParams, onRendered){return '<img width="30" height="30" alt="Image not found" src="/warning.jpg"/>'; }`
            }

```

**Modified Flow**

```auto
[{"id":"8a799d2cd04946d3","type":"debug","z":"731cf73c8837e83f","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":590,"y":380,"wires":[]},{"id":"8d06bd4ebc25bc6c","type":"ui_table","z":"731cf73c8837e83f","group":"b070d416.db371","name":"Thermostats","order":1,"width":"25","height":"7","columns":[],"outputs":1,"cts":true,"x":690,"y":460,"wires":[[]]},{"id":"3904341271fd2062","type":"function","z":"731cf73c8837e83f","name":"table data","func":"msg.payload = [\n {\n \"name\": \"MEQ0451495\",\n \"room\": \"Bathroom\",\n \"TEMPERATURE\": 22,\n \"ACTUAL TEMPERATURE\": 21.8,\n \"VALVE STATE\": 90,\n \"BATTERY STATE\": 2.7\n },\n\n {\n \"name\": \"MEQ1875547\",\n \"room\": \"Living Room\",\n \"TEMPERATURE\": 12,\n \"ACTUAL TEMPERATURE\": 16.2,\n \"VALVE STATE\": 10,\n \"BATTERY STATE\": 2.7\n },\n\n {\n \"name\": \"MEQ1875515\",\n \"room\": \"Living Room2\",\n \"TEMPERATURE\": 123,\n \"ACTUAL TEMPERATURE\": 16.2,\n \"VALVE STATE\": 35,\n \"BATTERY STATE\": 2.7\n },\n\n {\n \"name\": \"MEQ1875515\",\n \"room\": \"Living Room2\",\n \"TEMPERATURE\": 123,\n \"ACTUAL TEMPERATURE\": 16.2,\n \"VALVE STATE\": 100,\n \"BATTERY STATE\": 2.7\n },\n {\n \"name\": \"MEQ1875515\",\n \"room\": \"Living Room2\",\n \"TEMPERATURE\": 123,\n \"ACTUAL TEMPERATURE\": 16.2,\n \"VALVE STATE\": 70,\n \"BATTERY STATE\": 2.7\n }\n]\n\n\nmsg.ui_control = {\n \"tabulator\": {\n columns: [\n { title: \"Name\", field: \"name\", width: 200 },\n { title: \"Room\", field: \"room\", widthGrow: 1 },\n { title: \"TEMPERATURE\", field: \"TEMPERATURE\", align: \"center\" },\n { title: \"ACTUAL TEMPERATURE\", field: \"ACTUAL TEMPERATURE\", sorter: \"number\", align: \"center\" },\n {\n \"formatterParams\": {\n \"target\": \"_blank\", \"min\": 0, \"max\": 99, \"color\": [\"green\", \"orange\", \"red\"],\n \"legend\": \"function (value) {return (value>0)? '&nbsp;&nbsp;'+value+' %' : '-';}\",\n \"legendColor\": \"#101010\", \"legendAlign\": \"center\"\n },\n \"title\": \"VALVE STATE\", \"field\": \"VALVE STATE\", \"formatter\": \"progress\", \"width\": 100\n },\n { title: \"BATTERY STATE\", field: \"BATTERY STATE\", sorter: \"number\", align: \"center\" },\n {\n title: \"Action\", field: \"Action\", \"visible\": true, width: 100,\n \"formatter\": \"function(cell, formatterParams, onRendered){return '<button class=\\\"md-warn md-button \\\">Activate</button>'; }\"\n },\n {\n title: \"test\", field: \"test\", width: 50,\n \"formatter\": `function(cell, formatterParams, onRendered){return '<img width=\"30\" height=\"30\" alt=\"Image not found\" src=\"/warning.jpg\"/>'; }`\n }\n \n ]\n }\n}\n\n\n\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":460,"wires":[["8a799d2cd04946d3","8d06bd4ebc25bc6c"]]},{"id":"7466eb2b70a8cd74","type":"inject","z":"731cf73c8837e83f","name":"reset table","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"[]","payloadType":"json","x":500,"y":540,"wires":[["8d06bd4ebc25bc6c"]]},{"id":"ab7097a4786dee23","type":"inject","z":"731cf73c8837e83f","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":310,"y":460,"wires":[["3904341271fd2062"]]},{"id":"b070d416.db371","type":"ui_group","name":"Table","tab":"cd895ba5.a7168","order":1,"disp":true,"width":"25","collapse":false},{"id":"cd895ba5.a7168","type":"ui_tab","name":"newTable","icon":"dashboard","order":1,"disabled":false,"hidden":false}]

```

---

<div class="post-metadata">

### Author: ![oualid](https://avatars.discourse-cdn.com/v4/letter/o/8dc957/32.png) [@oualid](https://discourse.nodered.org/u/oualid)
#### Post date: [14 October 2021 01:21 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/7 "2021-10-14T01:21:14Z")

</div>

thanks a lot

---

<div class="post-metadata">

### Author: ![oualid](https://avatars.discourse-cdn.com/v4/letter/o/8dc957/32.png) [@oualid](https://discourse.nodered.org/u/oualid)
#### Post date: [15 October 2021 13:34 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/8 "2021-10-15T13:34:54Z")

</div>

hi @UnborN @Christian-Me ,

please i have another tow questions for you.  
in fact, using the same example given above, i want to display the value of the cell on the name of the button for ex: if the value of the cell is 5 so the button name should display 5 and so on.  
for that i tried the below code but did not work:

```auto
{ title: "TEMPERATURE", field: "TEMPERATURE", align: "center",
                "formatter": "function(cell, formatterParams, onRendered){var value= cell.getValue();" +
                                        "return '<button class=\"md-warn md-button \">value</button>'; }"
            }

```

my second question, i want to change the color of the button to warning color. please the find in the below what i did

```auto
{
                title: "Action", field: "Action", "visible": true, width: 100,
                "formatter": "function(cell, formatterParams, onRendered){return '<button class=\"md-warn md-button \">Activate</button>'; }"
            }

```

thanks a lot for your help

---

<div class="post-metadata">

### Author: ![UnborN](https://avatars.discourse-cdn.com/v4/letter/u/4491bb/32.png) [@UnborN](https://discourse.nodered.org/u/UnborN)
#### Post date: [15 October 2021 14:11 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/9 "2021-10-15T14:11:02Z")

</div>

> [@oualid](#):
>
> i want to display the value of the cell on the name of the button

What value exactly ? in your table there are several columns, with several values 😇

Try something like this :

```javascript
 {
   title: "Action", field: "Action", "visible": true, width: 100,
   "formatter": "function(cell, formatterParams, onRendered){ return '<button class=\"md-warn md-button\">Activate ' + cell._cell.row.data[\"TEMPERATURE\"] + '}</button>'; }"
            },

```

which at some point in the `return` string you have to close the single quote string and concatenate +  
`cell._cell.row.data[\"TEMPERATURE\"]` which is where the data is for each row.

regarding styling the button you can use css style tags. do md (material design classes work? dunno)

---

<div class="post-metadata">

### Author: ![Christian-Me](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/christian-me/32/10774_2.png) [@Christian-Me](https://discourse.nodered.org/u/Christian-Me)
#### Post date: [15 October 2021 14:27 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/10 "2021-10-15T14:27:28Z")

</div>

> [@UnborN](#):
>
> cell.\_cell.row.data

Avoid using the internal variables usually starting with \_. Even if this works now it could break in s feature update.  
Better use the get methods instead:

> **[Tabulator - Component Objects](https://tabulator.info/docs/4.0/components)**
>
> Component objects allow you to interact directly with the components that make up your tables, such as rows, columns and cells

---

<div class="post-metadata">

### Author: ![UnborN](https://avatars.discourse-cdn.com/v4/letter/u/4491bb/32.png) [@UnborN](https://discourse.nodered.org/u/UnborN)
#### Post date: [15 October 2021 14:47 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/11 "2021-10-15T14:47:25Z")

</div>

> [@Christian-Me](#):
>
> Avoid using the internal variables usually starting with \_.

Noted.

```javascript
{
title: "Action", field: "Action", "visible": true, width: 100,
"formatter": "function(cell, formatterParams, onRendered){ return '<button class=\"md-warn md-button\">Activate ' + cell.getData()[\"TEMPERATURE\"] + '</button>'; }"
},

```

---

<div class="post-metadata">

### Author: ![oualid](https://avatars.discourse-cdn.com/v4/letter/o/8dc957/32.png) [@oualid](https://discourse.nodered.org/u/oualid)
#### Post date: [15 October 2021 15:47 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/12 "2021-10-15T15:47:47Z")

</div>

thanks a lot

---

<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: [29 October 2021 15:48 UTC](https://discourse.nodered.org/t/how-insert-in-ui-table-an-image-in-each-row/52171/13 "2021-10-29T15:48:13Z")

</div>

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