# Use python to run toolbar function

**URL:** <https://discourse.slicer.org/t/use-python-to-run-toolbar-function/14708>\
**Category:** Support\
**Created:** [November 20, 2020, 11:49am UTC](https://discourse.slicer.org/t/use-python-to-run-toolbar-function/14708 "2020-11-20T11:49:26Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Changing](https://avatars.discourse-cdn.com/v4/letter/c/a183cd/32.png) [@Changing](https://discourse.slicer.org/u/Changing)\
**Post date:** [November 20, 2020, 11:49am UTC](https://discourse.slicer.org/t/use-python-to-run-toolbar-function/14708/1 "2020-11-20T11:49:26Z")

</div>

Hello,I want to know how can I use python python to run toolbar function in the 3D slicer.For example,I want to use python to run the next frame function automactically.I refer to the ScriptRepository examples and I try it as followed code.But after I run this code there is nothing happen in the 3D slicer.Where is wrong?Where can I learn more about this?

> playWidget = slicer.qMRMLSequenceBrowserPlayWidget()  
> playWidget.onVcrNext()
