Reputation: 713
How can I make easygui output to an easygui dialogue, rather than the terminal from which the x.py was invoked.
If I run my python script from a terminal, the easygui dialogue boxes appear and work, but the output is displayed in the terminal and not easygui.
Upvotes: 1
Views: 428
Reputation: 51
from easygui import *
name = "josh"
image = "gfg.png"
message = ("hello, my name is",name)
msgbox(message)
textbox(message)
input = buttonbox("message",image = image,choices=("hello","goodbye"))
i have not had to use any other easygui boxes at all, except enterbox.
msgbox outputs a simple, small message
textbox is used for larger outputs
buttonbox gives the option for input in response to the output. it also allows the output of images.
Upvotes: 0
Reputation: 58
easygui.msgbox('hello world', title='hello world', ok_button = 'yes')
that is a way to out put easygui msg
Upvotes: 2
Reputation: 713
The results need to be passed into the easygui syntax from a pre-declared variable. For example...
somemsg = "Some message"
sometitle = "Some title"
someresult = "Some result or text to include in easygui frame"
easygui.textbox(msg=somemsg, title=sometitle, text=someresult)
Upvotes: 1