title: How I can solved this name is not defined
body: <p>I want to make the program that I made can run
  i make code like this</p>
  <pre><code>def cafe_food(self):
      friedrice_items = tk.Entry(F_FItems)
      friedrice_items.config(width=7, borderwidth=4, relief=&quot;sunken&quot;, font=(&quot;calibri&quot;, 10,&quot;bold&quot;),foreground=&quot;white&quot;, background=&quot;#248aa2&quot;)
      friedrice_items.place(x=81, y=1)
  
  def Total_Biil(self):
      friedrice_price = 10
      pizza_price = 20
  
      if friedrice_items.get() != &quot;&quot;:
          friedrice_cost = friedrice_price * int(friedrice_items.get())
      else:
          friedrice_cost = 0
  
      if pizza_items.get() != &quot;&quot;:
          friedrice_cost = pizza_price * int(pizza_items.get())
      else:
          pizza_cost = 0
  
      total_bills = friedrice_cost + pizza_cost
  </code></pre>
  <p>if i run this code and..</p>
  <pre><code>Exception in Tkinter callback
  Traceback (most recent call last):
    File &quot;C:\Users\kisah tegar\AppData\Local\Programs\Python\Python39\lib\tkinter\__init__.py&quot;, line 1885, in __call__
      return self.func(*args)
    File &quot;D:\Code\Python\Project\restaurant_mg\main.py&quot;, line 498, in Total_Bill
      if friedrice_items.get() != &quot;&quot;:
  NameError: name 'friedrice_items' is not defined
  [Finished in 6.3s]
  </code></pre>
  <p>this my problem:(
  how can i get friedrice_items in that function</p>