title: How can I make an MDDataTable in another screen?
body: <p>I can't find a way to put an MDDataTable into a second screen after I press a button. I want to be able to display my table in the second screen when I press a button from the first screen. I don't know what to write to have the view_account function to run in my the account screen. There seems to be no way that the table can get to the second screen.
  The error I get is this</p>
  <pre><code>self.table.open()
   AttributeError: 'DemoApp' object has no attribute 'table'
  </code></pre>
  <pre><code>Window.size = (300, 500)
  
  screen_helper = &quot;&quot;&quot;
  ScreenManager:
      MenuScreen:
      AccountScreen:
  &lt;MenuScreen&gt;:
      name: 'menu'
      MDLabel:
          text: &quot;Login Page Test&quot;
          pos_hint: {'center_x':0.8, 'center_y':0.9}
      MDRectangleFlatButton:
          text: 'Proceed To Next Page'
          pos_hint: {'center_x':0.5, 'center_y':0.4}
          font_size : 20
          on_press:
              root.manager.current = 'account'   
              app.view_account()
  &lt;AccountScreen&gt;:
      name: 'account'
      MDLabel:
          text: 'Accounts Page Test'
          halign: 'center'
      
  &quot;&quot;&quot;
  
  
  class MenuScreen(Screen):
      pass
  
  class AccountScreen(Screen):
      pass
  
  sm = ScreenManager()
  sm.add_widget(MenuScreen(name='menu'))
  sm.add_widget(AccountScreen(name='account'))
  
  
  class DemoApp(MDApp):
  
      def build(self):
  
          screen = Builder.load_string(screen_helper)
          return screen
  
      def view_account(self):
          rows = []
          table = MDDataTable(pos_hint={'center_x': .5, 'center_y': .6},
                              size_hint=(.9, 0.7),
                              check=True,
                              rows_num=30,
                              column_data=[
                                  (&quot;Type.&quot;, dp(38)),
                                  (&quot;Balance&quot;, dp(20)),
                                  (&quot;Date&quot;, dp(20)),
                                  (&quot;id&quot;, dp(20))
                              ],
                              row_data=rows
                              )
          table.bind(on_check_press=self.check_press)
          table.bind(on_row_press=self.row_press)
          close_button1 = MDFlatButton(text='Close', on_release=self.close_view)
          self.table.open()
  
      def row_press(self, instance_table, instance_row):
          print(instance_table, instance_row)
  
  
  DemoApp().run()
  </code></pre>