Skip to content
Advertisement

PySimpleGui – How can I update GUI with a question but not check for the answer during the first iteration

I am making a quiz program in PySimpleGui. I want it so that the first question appears automatically without pressing a button. Is there a way to do this without adding the question in the layout? With the code below the question only appears after the submit button is pressed.

I would prefer it not to be in the layout as I would like people to make their own quizzes without writing any code themselves.

JavaScript

Advertisement

Answer

I add this two-line code, you can use visible=True and after run the program makes this visible=False, like This:

JavaScript

final code:

JavaScript
User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement