title: Is there a way to get the Column menu updates automatically with the sheet menu?
body: <p>I am devoloping an app where the user upload his excel file and gets the Sheets and columns. How do I get the Columns drop-down menu (The second one) to update with the Sheets drop-down menu(First one).</p>
  
  <p>I have already tried to make a function 'Update' that gets the new sheet form the Fuction 'GetSheet' and update it. But it does not work as the column drop-down menu get Always stucked in the Default sheet.</p>
  
  <pre><code>master.title('ATT Analytics App')
  master.geometry("400x250")
  
  Myfile= filedialog.askopenfile()
  wb = load_workbook(filename = str(Myfile.name))
  #Sheets = wb.sheetnames
  
  
  variable = StringVar(master)
  variable.set(str(wb.sheetnames[2])) # default value
  w = OptionMenu(master, variable, str(wb.sheetnames[0]), str(wb.sheetnames[1]), str(wb.sheetnames[2]), str(wb.sheetnames[3]))
  w.pack()
  
  
  
  def GetSheet():
      FileRead = pd.read_excel(str(Myfile.name),sheet_name= str(variable.get())) 
      MyHeadres = list(FileRead.columns.values)
      return MyHeadres, FileRead
  
  variable1 = StringVar(master)
  
  def Update(TheHeaders):
      variable1.set(str(TheHeaders[0]))
      wc = OptionMenu(master, variable1, str(TheHeaders[0]), str(TheHeaders[1]), str(TheHeaders[2]), str(TheHeaders[3]), str(TheHeaders[4]), str(TheHeaders[5]))
      return wc
  
  def RunAll():
      GetMySheet, FileRead = GetSheet()
      UpdateMysheet = Update(GetMySheet)
      return UpdateMysheet, variable1.get(), FileRead 
  
  button = Button(master, text="Run", command=RunAll)
  button.pack(side = TOP)
  
  UpdateMysheet, MyColumn, ReadMyFile = RunAll()
  UpdateMysheet.pack()
  FileRead = ReadMyFile
  
  mainloop()
  </code></pre>
  
  <p>I want to bring my Code to be able to update the Column Drop-down (Variable1) menu with the drop down menu (Variable), which works fine and also get to store the column you want and move on the choose another one and so on..
  I would appreciate your help a lot.</p>
  
  <p>Edit: Now when I choose another sheet, the Default value of the columns updates to the new sheet, but when I look the complete List, I find out that the values are from the old sheet.</p>