Pysimplegui: Question: How to Clear the OUTPUT Element

Created on 19 May 2019  路  5Comments  路  Source: PySimpleGUI/PySimpleGUI

Type of Issues (Enhancement, Error, Bug, Question)

Question

Operating System

Linux

Python version

Python 3.6

PySimpleGUI Port and Version

PySimpleGUI Python 3.29

Code or partial code causing the problem

Is there away to clear the OUTPUT element of all output?

Most helpful comment

Perhaps you can try this.

Given an output element
[sg.Output(size=(80, 20), key = '_output_')],

You can clear it with.
window.FindElement('_output_').Update('')

All 5 comments

Perhaps you can try this.

Given an output element
[sg.Output(size=(80, 20), key = '_output_')],

You can clear it with.
window.FindElement('_output_').Update('')

LOVE it when the community comes together to answers questions for each other.

@fsmosca thank you that worked. Easy when you know how.

I think the next time you print after clearing the output it prints all the previous output at least in Web interface

@kpsychas
If you have an issue to report, please open a new issue.
It appears your issue is on PySimpleGUIWeb and you've replied to an issue that was closed over a year ago that was on the tkinter port.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

martinmeteor picture martinmeteor  路  4Comments

MikeTheWatchGuy picture MikeTheWatchGuy  路  3Comments

yogesh-aggarwal picture yogesh-aggarwal  路  3Comments

MikeTheWatchGuy picture MikeTheWatchGuy  路  5Comments

MikeTheWatchGuy picture MikeTheWatchGuy  路  6Comments