How to save a textbox value for later use

I want to be able to store a value that is updated in a text box every second, so that if I redeploy it will be able to start from that value instead of zero.

Set Persistance on flow or global variables. Use an inject set for first pass only to push the saved, persistent value to your desired message.

How do i set persistence?

when you run the node-red command it will show you your file locations. Details are found in your
settings.js file.

30 Jul 16:41:08 - [info] Settings file  : /home/myname/.node-red/settings.js
30 Jul 16:41:08 - [info] Context store  : 'default' [module=memory]
30 Jul 16:41:08 - [info] User directory : /home/myname/.node-red
30 Jul 16:41:08 - [warn] Projects disabled : editorTheme.projects.enabled=false
30 Jul 16:41:08 - [info] Flows file     : /home/myname/.node-red/flows.json
30 Jul 16:41:08 - [info] Server now running at

Then in the Settings file content. search "Content Storage"

    /** Context Storage
     * The following property can be used to enable context storage. The configuration
     * provided here will enable file-based context that flushes to disk every 30 seconds.
     * Refer to the documentation for further options:
    //contextStorage: {
    //    default: {
    //        module:"localfilesystem"
    //    },

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