Answers for "tkinter text input value"

1

print textbox value in tkinter

import tkinter as tk
root = tk.Tk()
root.geometry("400x240")

def getTextInput():
    result=textExample.get("1.0","end")
    print(result)

textExample=tk.Text(root, height=10)
textExample.pack()
btnRead=tk.Button(root, height=1, width=10, text="Read", 
                    command=getTextInput)

btnRead.pack()

root.mainloop()
Posted by: Guest on October-30-2020
4

tkinter input text box

from tkinter import *


textBox = Entry(text="Placeholder text")
Posted by: Guest on June-11-2021

Browse Popular Code Answers by Language