# How to reset add node

**URL:** https://discourse.nodered.org/t/how-to-reset-add-node/83166
**Category:** General
**Created:** [25 November 2023 04:15 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166 "2023-11-25T04:15:56Z")
**Posts on this page:** 12
**Page:** 1

<div class="post-metadata">

### Author: ![rmystique](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/rmystique/32/84365_2.png) [@rmystique](https://discourse.nodered.org/u/rmystique)
#### Post date: [25 November 2023 04:15 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/1 "2023-11-25T04:15:56Z")

</div>

How do I reset a add node, Ideally I want it to reset on the 28th of every month?

---

<div class="post-metadata">

### Author: ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)
#### Post date: [25 November 2023 08:13 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/2 "2023-11-25T08:13:04Z")

</div>

What add node? Are you talking about a contrib node that you have installed?

---

<div class="post-metadata">

### Author: ![rmystique](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/rmystique/32/84365_2.png) [@rmystique](https://discourse.nodered.org/u/rmystique)
#### Post date: [26 November 2023 16:44 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/3 "2023-11-26T16:44:41Z")

</div>

yes, under function nodes

---

<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: [26 November 2023 16:48 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/4 "2023-11-26T16:48:07Z")

</div>

I believe @Colin is asking you what is th full name of the node? i.e. node-red-contrib-?????

Even more helpful would be to create a small flow demonstrating your problem and exporting it and attaching it to a reply. Then people can see what you are doing and help you out.

---

<div class="post-metadata">

### Author: ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)
#### Post date: [26 November 2023 16:58 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/5 "2023-11-26T16:58:48Z")

</div>

Do you mean you have written a function node and you want to reset it in some way? We are not telepathic so we have no idea what you have written in the function node, so have no way of knowing how to reset it. If that is what you are trying to do then post the contents of the function node here.

---

<div class="post-metadata">

### Author: ![rmystique](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/rmystique/32/84365_2.png) [@rmystique](https://discourse.nodered.org/u/rmystique)
#### Post date: [26 November 2023 17:06 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/6 "2023-11-26T17:06:26Z")

</div>

I want to be able to have it start over at some interval like 7 days or 28 days:

```auto
[
    {
        "id": "b05ed350cffaa8ab",
        "type": "add",
        "z": "f672d0ac69fd5b97",
        "name": "",
        "topic": "",
        "x": 330,
        "y": 1140,
        "wires": [
            [
                "79181d172ce19f5b"
            ]
        ]
    },
    {
        "id": "79181d172ce19f5b",
        "type": "ui_text",
        "z": "f672d0ac69fd5b97",
        "group": "8ee0bb75fa4e2113",
        "order": 21,
        "width": 0,
        "height": 0,
        "name": "",
        "label": "Display",
        "format": "{{msg.payload}}",
        "layout": "row-spread",
        "className": "",
        "style": false,
        "font": "",
        "fontSize": 16,
        "color": "#000000",
        "x": 480,
        "y": 1140,
        "wires": []
    },
    {
        "id": "ccf318f969b984e9",
        "type": "inject",
        "z": "f672d0ac69fd5b97",
        "name": "inject",
        "props": [
            {
                "p": "payload"
            }
        ],
        "repeat": "5",
        "crontab": "",
        "once": true,
        "onceDelay": "1",
        "topic": "",
        "payload": "1",
        "payloadType": "num",
        "x": 170,
        "y": 1140,
        "wires": [
            [
                "b05ed350cffaa8ab"
            ]
        ]
    },
    {
        "id": "8ee0bb75fa4e2113",
        "type": "ui_group",
        "name": "Main",
        "tab": "9d03c9290d696c27",
        "order": 1,
        "disp": false,
        "width": 12,
        "collapse": false,
        "className": ""
    },
    {
        "id": "9d03c9290d696c27",
        "type": "ui_tab",
        "name": "Solar Power Stats",
        "icon": "dashboard",
        "disabled": false,
        "hidden": false
    }
]

```

---

<div class="post-metadata">

### Author: ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)
#### Post date: [26 November 2023 17:18 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/7 "2023-11-26T17:18:35Z")

</div>

I think, as @zenofmud suggested, you have installed a package that provides the add node. You need to tell us what it is. Look in Manage Palette to see what you have installed.

---

<div class="post-metadata">

### Author: ![jbudd](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jbudd](https://discourse.nodered.org/u/jbudd)
#### Post date: [26 November 2023 17:30 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/8 "2023-11-26T17:30:42Z")

</div>

Assuming that the "add node" is **node-red-contrib-ad** d, it can be reset by sending a message including. msg.reset.

You could use **node-red-contrib-cronplus** to send a message on the 28th of the month.  
I think the cron expression for this would be `0 30 1 28 * ? *` (at 01:30 on 28th of every month) but there is an "Easy expression builder" available from the dropdown.

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/e/5/e5c3e649f55b2d551b44e0c913a6f8e557b65bbc.png)

Send the output from cronplus through a change node to give msg.reset a value.  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/d/0/d0999f7cfb09c4a20774b9ac0f40d7ce3b13a0a3.png)

```auto
[{"id":"83b6ded529191494","type":"cronplus","z":"412898c785d3620d","name":"","outputField":"payload","timeZone":"","storeName":"","commandResponseMsgOutput":"output1","defaultLocation":"","defaultLocationType":"default","outputs":1,"options":[{"name":"schedule1","topic":"topic1","payloadType":"default","payload":"","expressionType":"cron","expression":"0 30 1 28 * ? *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}],"x":280,"y":360,"wires":[["bce07f70997c5477"]]},{"id":"bce07f70997c5477","type":"change","z":"412898c785d3620d","name":"","rules":[{"t":"set","p":"reset","pt":"msg","to":"","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":460,"y":360,"wires":[["1b2560b974c05c1f"]]}]

```

---

<div class="post-metadata">

### Author: ![Sean-McG](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/sean-mcg/32/54677_2.png) [@Sean-McG](https://discourse.nodered.org/u/Sean-McG)
#### Post date: [26 November 2023 17:51 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/9 "2023-11-26T17:51:12Z")

</div>

> [@Colin](#):
>
> telepathic

Mystic @jbudd to the rescue 😉

---

<div class="post-metadata">

### Author: ![jbudd](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jbudd](https://discourse.nodered.org/u/jbudd)
#### Post date: [26 November 2023 18:01 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/10 "2023-11-26T18:01:25Z")

</div>

Pah.

I just went to [flows.nodered.org](http://flows.nodered.org), searched for add and worked through the 12 pages of results to find one which might be an "add node, yes contrib and under function node".  
Then I installed it and edited my flows file to verify that the node-type is shown as "add".  
Anybody could have done it.  
And here it is, under Function!

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

Simples, though possibly erroneous.

---

<div class="post-metadata">

### Author: ![rmystique](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/rmystique/32/84365_2.png) [@rmystique](https://discourse.nodered.org/u/rmystique)
#### Post date: [26 November 2023 18:25 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/11 "2023-11-26T18:25:25Z")

</div>

Thank you!

---

<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: [10 December 2023 18:26 UTC](https://discourse.nodered.org/t/how-to-reset-add-node/83166/12 "2023-12-10T18:26:17Z")

</div>

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