title: I am trying to create a set of pop of windows to determine a varying number of xy coords
body: <p>I am trying to create a series of two pop of windows where the first will determine the number of coordinates the user will input and the second will allow the user to input this exact number of coordinates.</p>
  
  <p>My code for the first pop up works and looks like this:</p>
  
  <pre><code>root = Tk()
  root.title("User Inputs")
  
  mainframe = ttk.Frame(root, padding="3 3 12 12")
  mainframe.grid(column=0, row=0, sticky=(N, W, E, S))
  mainframe.columnconfigure(0, weight=1)
  mainframe.rowconfigure(0, weight=1)
  
  numofcoord = StringVar()
  
  numofcoord = ttk.Entry(mainframe, width=7, textvariable=numofcoord)
  numofcoord.grid(column=2, row=1, sticky=(W, E))
  
  ttk.Button(mainframe, text="OK", command=user_coordinates).grid(column=1,    row=2, sticky=W)
  ttk.Button(mainframe, text="CANCEL", command=quit).grid(column=2, row=2, sticky=W)
  
  ttk.Label(mainframe, text="Number of Coordinates").grid(column=1, row=1, sticky=W)
  
  for child in mainframe.winfo_children(): child.grid_configure(padx=5, pady=5)
  
  root.mainloop()
  </code></pre>
  
  <p>The first section works, but in the second section, my pop up looks like this where the number of rows is determined by the input in the first pop up window.</p>
  
  <p><a href="http://i.imgur.com/dToI2qX.png" rel="nofollow">http://i.imgur.com/dToI2qX.png</a></p>
  
  <p>the code for the second section looks like this:</p>
  
  <pre><code>try:
      noc = int(numofcoord.get())
      root = Tk()
      root.title("User Defined Coordinates")
  
      mainframe = ttk.Frame(root, padding="3 3 12 12")
      mainframe.grid(column=0, row=0, sticky=(N, W, E, S))
      mainframe.columnconfigure(0, weight=1)
      mainframe.rowconfigure(0, weight=1)
  
      x = StringVar()
      y = StringVar()
  
      ttk.Label(mainframe, text="X").grid(column=1, row=1, sticky=(W, E))
      ttk.Label(mainframe, text="Y").grid(column=2, row=1, sticky=(W, E))
  
      for i in range(2, noc + 2):
          xcoord = ttk.Entry(mainframe, width=7, textvariable=x)
          xcoord.grid(column=1, row=i, sticky=(W, E))
  
          ycoord = ttk.Entry(mainframe, width=7, textvariable=y)
          ycoord.grid(column=2, row=i, sticky=(W, E))
  
      ttk.Button(mainframe, text="OK", command=test).grid(column=1, row=noc + 3, sticky=W)
      ttk.Button(mainframe, text="CANCEL", command=quit).grid(column=2, row=noc + 3, sticky=W)
  
      for child in mainframe.winfo_children(): child.grid_configure(padx=5, pady=5)
  
      root.mainloop()
  
  except ValueError:
      pass
  </code></pre>
  
  <p>The issue is that in when you put a value in either the X or Y column, every box in that column is filled with that value and I would like for each row to be a set of coordinates. </p>