title: NoneType object has no attribute yview
body: <p>first of all I want to get it out of the way that I am aware of this question: <a href="https://stackoverflow.com/questions/21255216/python-tkinter-attributeerror-nonetype-object-has-no-attribute-xview">Python - tkinter &#39;AttributeError: &#39;NoneType&#39; object has no attribute &#39;xview&#39;&#39;</a></p>
  
  <p>However, after reading this I am still confused as to what the issue is. I have a program that uses Tkinter. In it, there are two text boxes that the user can type text into. I want those boxes to be scrollable. However, I have an issue with doing this. Here's my code: </p>
  
  <pre><code>from Tkinter import *
  
  def main():
      window = Tk()
      window.title("TexComp")
      window.geometry("500x500")
      window.resizable(height=FALSE,width=FALSE)
  
      windowBackground = '#E3DCA8'
  
      window.configure(bg=windowBackground)
  
      instruction = Label(text="Type or paste your text into one box,\nthen paste the text you want to compare it too\ninto the other one.", bg=windowBackground).place(x=115, y=10)
  
      text1 = Text(width=25).pack(side=LEFT)
      text2 = Text(width=25).pack(side=RIGHT)
  
      scroll1y=Scrollbar(window, command=text1.yview).pack(side=LEFT, fill=Y, pady=65)
      scroll2y=Scrollbar(window, command=text2.yview).pack(side=RIGHT, fill=Y, pady=65)
  
      mainloop()
  
  if __name__ == '__main__':
      main()
  </code></pre>
  
  <p>When I try to run this, I get an error saying "'NoneType' object has no attribute 'yview'" on the scroll1y and scroll2y scrollbars. I am unsure as to why this is and have been unable to find a clear answer. Thank you for your time.</p>