# How to make an auto scroll debug textbox

**URL:** https://discourse.nodered.org/t/how-to-make-an-auto-scroll-debug-textbox/51891
**Category:** Dashboard
**Created:** [5 October 2021 20:17 UTC](https://discourse.nodered.org/t/how-to-make-an-auto-scroll-debug-textbox/51891 "2021-10-05T20:17:22Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![tcontrada](https://avatars.discourse-cdn.com/v4/letter/t/f1d935/32.png) [@tcontrada](https://discourse.nodered.org/u/tcontrada)
#### Post date: [5 October 2021 20:17 UTC](https://discourse.nodered.org/t/how-to-make-an-auto-scroll-debug-textbox/51891/1 "2021-10-05T20:17:22Z")

</div>

I am able to make a simple text area using the Template UI Node where I can place debug messages, etc. However, I want it to auto scroll to the last item that was added.

What's the solution to making a debug text box that auto scrolls using the Template node?

Thanks...

---

<div class="post-metadata">

### Author: ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)
#### Post date: [5 October 2021 20:18 UTC](https://discourse.nodered.org/t/how-to-make-an-auto-scroll-debug-textbox/51891/2 "2021-10-05T20:18:56Z")

</div>

> [@Where can I find (or enable) an "interactive" console in node-red?](https://discourse.nodered.org/t/where-can-i-find-or-enable-an-interactive-console-in-node-red/45905/15):
>
> You could achieve this with a simple pre & code block. You can even have syntax highlighting and a MAX LENGTH buffer for scroll back. example... [xSa2xxlzm7] Demo flow... [{"id":"ca8f65c0.635a58","type":"ui\_template","z":"553814a2.1248ec","group":"6d01ec93.b1d374","name":"","order":7,"width":"12","height":"8","format":"\n\<!--\<pre\>\<code id=\"shell\" class=\"language-bash bash\" ng-bind=\"msg.payload\"\>\</code\>\</pre\>--\>\n\<pre\>\<code id=\"shell\" class=\"language-bash bash\"\>\</code\>\</pre\>\n\n\<sc…

or

> [@Where can I find (or enable) an "interactive" console in node-red?](https://discourse.nodered.org/t/where-can-i-find-or-enable-an-interactive-console-in-node-red/45905/22):
>
> ok - 20 minutes slight_smile Here is an alternative version that uses [ansi-to-html](https://www.npmjs.com/package/ansi-to-html)NOTE: You will need node-red V1.3.x as this demo uses [function external modules](https://nodered.org/docs/user-guide/writing-functions#using-the-functionexternalmodules-option) [Us8oCqVmtk] [{"id":"270e0d17.f1c9b2","type":"ui\_template","z":"553814a2.1248ec","group":"6d01ec93.b1d374","name":"","order":7,"width":"12","height":"8","format":"\n\<div id=\"shell\" style=\"font-family: monospace;\"\>\</div\>\n\n\<script\>\n(function(scope) {\n scope.$watch('msg', function(msg) {\n if (msg) {\n debugger…

---

<div class="post-metadata">

### Author: ![tcontrada](https://avatars.discourse-cdn.com/v4/letter/t/f1d935/32.png) [@tcontrada](https://discourse.nodered.org/u/tcontrada)
#### Post date: [5 October 2021 20:27 UTC](https://discourse.nodered.org/t/how-to-make-an-auto-scroll-debug-textbox/51891/3 "2021-10-05T20:27:44Z")

</div>

I'm looking for something that I can use in the NR Dashboard, and is simple, not a huge flow.

Thanks

---

<div class="post-metadata">

### Author: ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)
#### Post date: [5 October 2021 20:47 UTC](https://discourse.nodered.org/t/how-to-make-an-auto-scroll-debug-textbox/51891/4 "2021-10-05T20:47:01Z")

</div>

Those 2 solutions are for node-red dashboard.

---

<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: [6 October 2021 05:05 UTC](https://discourse.nodered.org/t/how-to-make-an-auto-scroll-debug-textbox/51891/5 "2021-10-06T05:05:26Z")

</div>

Perhaps using ui-table?

This flow can display a log (use the limiter mod in the following post too)

> [@Problem with data displayed in UI-Table when switching Tabs](https://discourse.nodered.org/t/problem-with-data-displayed-in-ui-table-when-switching-tabs/48940/7):
>
> So something like a logfile .... This is using a little bit more complex (but universal) subflow I use for all my tables. But you can do it more simple too: A) a function node which gets an array (of lines) from the flow context and pushes the new line at the end B) a second function node triggered by ui-control gets the same context array and send it to ui-table I splittend it up to different nodes to make it easier to understand / debug - The tricky part is to scroll the table if you in…

---

<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: [5 November 2021 05:05 UTC](https://discourse.nodered.org/t/how-to-make-an-auto-scroll-debug-textbox/51891/6 "2021-11-05T05:05:56Z")

</div>

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