title: tkinter can't convert entry string to int
body: <p>I have an entry widget in a class (StartPage) where I have to put numbers, the input is saved in a general class (Variabili) which is accessible from another class (FirstPage). Based on that number I have to istanciate n labels (where n is the number i put in the previous page). To do that I used a for loop:  <code>for i in range(0, int(number))</code>. And here's the problem:
  I keep getting this error: <code>TypeError: IntVar() missing 1 required positional argument: 'name'</code></p>
  <p>Down here's the code:</p>
  <pre><code>import tkinter as tk                # python 3
  from tkinter import font as tkfont
  from typing_extensions import IntVar  # python 3
  
  
  class SampleApp(tk.Tk):
  
      def __init__(self, *args, **kwargs):
          tk.Tk.__init__(self, *args, **kwargs)
  
          self.title_font = tkfont.Font(family='Helvetica', size=18, weight=&quot;bold&quot;, slant=&quot;italic&quot;)
  
          # the container is where we'll stack a bunch of frames
          # on top of each other, then the one we want visible
          # will be raised above the others
          container = tk.Frame(self)
          container.pack(side=&quot;top&quot;, fill=&quot;both&quot;, expand=True)
          container.grid_rowconfigure(0, weight=1)
          container.grid_columnconfigure(0, weight=1)
  
          
  
          self.frames = {}
          for F in (StartPage, PageOne):
              page_name = F.__name__
              frame = F(parent=container, controller=self)
              self.frames[page_name] = frame
  
              # put all of the pages in the same location;
              # the one on the top of the stacking order
              # will be the one that is visible.
              frame.grid(row=0, column=0, sticky=&quot;nsew&quot;)
  
          self.show_frame(&quot;StartPage&quot;)
  
      def show_frame(self, page_name, *args):
          '''Show a frame for the given page name'''
          frame = self.frames[page_name]
          frame.tkraise()
  
      def get_page(self, classname):
          '''Returns an instance of a page given it's class name as a string'''
          for page in self.frames.values():
              if str(page.__class__.__name__) == classname:
                  return page
          return None
  
  
  
  class Variabili: 
      numero_finanziatori = tk.IntVar()
      
  class StartPage(tk.Frame, Variabili):
  
      def __init__(self, parent, controller):
          tk.Frame.__init__(self, parent)
          self.controller = controller
  
          
          #label = tk.Label(self, text=&quot;Start Page: insert value&quot;)
          #label.pack(side=&quot;top&quot;, fill=&quot;x&quot;, pady=10)
          #self.some_input = tk.IntVar()
          #self.some_entry = tk.Entry(self, width=8, textvariable=self.some_input).pack()
          
  
          self.some_input = tk.StringVar()
          self.some_entry = tk.Entry(self, width=8, textvariable=Variabili.numero_finanziatori)
          self.some_entry.insert(0, &quot;1&quot;)
          self.some_entry.pack()
          Variabili.numero_finanziatori = self.some_entry.get()
          
          button1 = tk.Button(self, text='Next Page', command=lambda: controller.show_frame(&quot;PageOne&quot;))
          button1.pack()
  
  class PageOne(tk.Frame, Variabili):   
  
      def __init__(self, parent, controller):
          tk.Frame.__init__(self, parent)
          self.controller = controller
  
          
          labels_finanziatori = {
          'principale': [],
          'capitale_investito': [], 
          'tasso': [], 
          'tempo': []
          }
          dict_finanziatori = {
          'numero': [],
          'capitale_investito': [], 
          'tasso': [], 
          'tempo': [],
          }
          Finanziatore_Semplice = []
  
          k = 0
  
          for i in range(0, int(Variabili.numero_finanziatori)): 
              #MAIN label del finanziatore
              labels_finanziatori['principale'].append(tk.Label(self, text=&quot;Dati finanziatore numero &quot;+str(i+1) +&quot;:\n&quot;))
              labels_finanziatori['principale'][i].grid(row=i*(k+1), column = 0)
              k = k+1
              button = tk.Button(self, text=&quot;Go to the start page&quot;,
                             command=lambda: controller.show_frame(&quot;StartPage&quot;)).grid()
  
  if __name__ == &quot;__main__&quot;:
      app = SampleApp()
      app.mainloop()
  </code></pre>
  <p>And here's the traceback i get:</p>
  <pre><code>File &quot;c:/Users/trevi/Documents/WorkInProgress/Python/V0_3/backbone4.py&quot;, line 50, in &lt;module&gt;
      class Variabili:
    File &quot;c:/Users/trevi/Documents/WorkInProgress/Python/V0_3/backbone4.py&quot;, line 51, in Variabili
      numero_finanziatori = tk.IntVar()
    File &quot;C:\Users\trevi\Anaconda\Anaconda3\lib\tkinter\__init__.py&quot;, line 502, in __init__
      Variable.__init__(self, master, value, name)
    File &quot;C:\Users\trevi\Anaconda\Anaconda3\lib\tkinter\__init__.py&quot;, line 317, in __init__
      self._root = master._root()
  AttributeError: 'NoneType' object has no attribute '_root'
  
  </code></pre>