title: Python, Tkinter: NameError: global name 'Combobox' is not defined
body: <p>I have created a combobox for my gui application in Python but I have been getting this error when declaring my combobox in my <strong>init</strong> function: </p>
  
  <p><code>TypeError: 'Combobox' object is not callable</code></p>
  
  <p>Here is the code I am using for this:</p>
  
  <pre><code>class ProgramingPractice(Tk):
  
      def __init__(self):
          super(ProgramingPractice, self).__init__()
          self.variableCombo_value = StringVar()
          self.variableCombo = ttk.Combobox()
  
       def questionVariables(self):
  
          self.variableCombo_value = StringVar()
          self.variableCombo(self.formSize, textvariable = self.variableCombo, state = 'readonly')
          self.variableCombo['values'] = ('Month', 'Year', 'Age', 'Day')
          self.variableCombo.pack()
  </code></pre>
  
  <p>I have tried different solutions to this problem but I have either got an Attibute error or a name error. </p>
  
  <p>Does anyone know of a solution to this problem?</p>
  
  <p>This is the smallest I can make the code while still getting the error:</p>
  
  <pre><code>import sys
  from tkinter import *
  from tkinter import ttk
  
  
  class ProgramingPractice(Tk):
  
      def __init__(self):
          super(ProgramingPractice, self).__init__()
          self.formSize()
          self.variableCombo_value = StringVar()
          self.variableCombo = ttk.Combobox()
  
  
      def formSize(self):
          self.geometry("700x450+200+200") # Sets the size of the gui
  
      def questionVariables(self):
  
          self.variableCombo_value = StringVar()
          self.variableCombo.configure(self.formSize, textvariable = self.variableCombo_value, state = 'readonly')
          self.variableCombo['values'] = ('Month', 'Year', 'Age', 'Day')
          self.variableCombo.pack()
  
  
  pp = ProgramingPractice()
  pp.questionVariables()
  </code></pre>