title: How to get the entry text and display in another entry?
body: <p>I just want that when I type my name inside the entry box then appears in another entry with some add text. The idea is type in the entry below and after that it showed in the big entry.I was looking for this solution, but just found place in Label. I don't want in Label. The window is more big, must drag to show the entry. There's is a picture that i use in this script:</p>
  
  <pre><code>from tkinter import *
  from PIL import Image, ImageTk
  
  root = Tk()
  
  cat = Entry(root)
  cat.place(x=48, y=25, width= 350, height=140)
  
  user = Entry(root)
  user.place(x=75, y=550)
  
  btn = Button(root, text='START')
  btn.place(x=220, y=410)
  
  root.mainloop()
  </code></pre>
  
  #
  
  <p>Ok, It works the way you told me,thank you!</p>
  
  <p>But now i'm facing another problem.</p>
  
  <p>The problem is when i insert the function of the game in the second window. I tested in one window and it works, but when i place the function in the second window gives an error when i press the "Start" button:
  '''user_try = int(txt.get())
  NameError: name 'txt' is not defined'''</p>
  
  <p>When i press reset button gives another error:
  '''user_try = int(txt.get())
  NameError: name 'txt' is not defined'''</p>
  
  <p>So i know that is missing definition, but i don't know how to make a reference for this command that it's in the second window. Like i said running with just one window the program works.</p>
  
  <p>Maybe i should make using class, i don't know, but i wish to make this way that i started. However if there's no other way to do as i'm doing, let's go.</p>
  
  <p>I just simplify the script here, actualy the main script is more bigger, so my idea is when open the program, there is a window and the user read the instructions about the game and proceed open the second window. The window have pictures and some hidden buttons in the next picture, so there will be an interactivity with the environment.
  The guess number is just the beggining. After that there will be new challeges.
  I'm very excited doing this, but i'm stuck in this point. The part one i finished, the pictures, the hidden buttons it's exacly the way i want, but the challenge stops here in this problem.</p>
  
  <pre><code>from tkinter import *
  from PIL import Image, ImageTk, ImageSequence
  import random
  from tkinter import messagebox
  
  pc = random.randint(1,10)
  
  def reset():
  global pc
  pc = random.randint(1,10)
  cat['text'] = 'Ok! Lets Try Again!'
  
  def openwin2():
  win1.withdraw()
  win2 = Toplevel()
  win2.geometry('350x300+180+100')
  win2.title('second window')
  txt = Entry(win2)
  txt.place(x=10,y=10)
  cat = Label(win2,wraplength=300)
  cat.place(x=10,y=50)
  cat.config(text='Hi! I Am thinking a number between 1 and 10.')
  btn = Button(win2,text='start',command=check)
  btn.place(x=30, y=150)
  
  btn2 = Button(win2, text='reset', command=reset)
  btn2.place(x=110,y=150)
  win2.mainloop()
  def check():
  
  user_try = int(txt.get())
  if user_try &lt; pc:
      msg = 'Hmmmm... the number, which I thought of, is greater than this.'
  elif user_try &gt; pc:
      msg = 'How about trying a smaller number ?!'
  elif user_try == pc:
      msg = 'Well Done! You guessed! It was %s the number!' % user_try
  else:
      msg = 'Something Went Wrong...'
  
  cat['text'] = msg
  
  win1 = Tk()
  
  win1.title('First Window')
  win1.geometry('350x300')
  
  user = Label(win1,text='first window')
  user.place(x=10,y=10)
  
  btn1 = Button(win1,text='Open Window 2', command=openwin2)
  btn1.place(x=10,y=50)
  
  
  win1.mainloop()
  </code></pre>