# How to reset the n\_clicks of a button and value of the input text box after the every callback? Please help

**URL:** <https://community.plotly.com/t/how-to-reset-the-n-clicks-of-a-button-and-value-of-the-input-text-box-after-the-every-callback-please-help/29571>\
**Category:** Dash Python\
**Created:** [October 4, 2019, 12:05am UTC](https://community.plotly.com/t/how-to-reset-the-n-clicks-of-a-button-and-value-of-the-input-text-box-after-the-every-callback-please-help/29571 "2019-10-04T00:05:19Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![wbrgss](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/wbrgss/32/3621_2.png) [@wbrgss](https://community.plotly.com/u/wbrgss)\
**Post date:** [October 7, 2019, 10:12pm UTC](https://community.plotly.com/t/how-to-reset-the-n-clicks-of-a-button-and-value-of-the-input-text-box-after-the-every-callback-please-help/29571/4 "2019-10-07T22:12:28Z")

</div>

Since you mentioned the “Reset” button, I assume you have seen [this discussion](https://community.plotly.com/t/how-to-implement-reset-button-to-clear-output/15701), which uses the following callback:

```auto
@app.callback(Output('input_button','n_clicks'),
             [Input('reset_button','n_clicks')])
def update(reset):
    return 0

```

now, since you don’t want a “Reset Button”, can you make the input to the callback one, or all, of (“the button click or by tab clicks or by slider [click]”) — i.e. the components that trigger the page reload? These components may update other Outputs, but you should be able to simultaneously update the DCC `n_clicks` value, or the `html.Input` value, using the [multiple outputs](https://community.plotly.com/t/multiple-outputs-in-dash-now-available/19437) feature.

This would look something like this:

```auto
# reset 
@app.callback([Output('show_button','n_clicks'),
               Output('text_input','value'),
               Output('my_op_result','value')],
             [Input('my_reload_button','n_clicks'),
              Input('my_reload_tab','value'),
              Input('my_reload_slider','value')])
def update(no_clicks, value1, value2):
    my_result = do_my_op()
    return 0, '', my_result

```

---

_[View the full topic](https://community.plotly.com/t/how-to-reset-the-n-clicks-of-a-button-and-value-of-the-input-text-box-after-the-every-callback-please-help/29571)._
