0

help needed. I wanted to do a recycle, but when I run the code, and go to recycleview's screen, nothing appears. Only a screen with a specific color on the background. I wanted to do a recycle view with a viewclass of button. Here is the code :

class ReviewinApp(MDApp):
    data = [{'text':str(i)} for i in range(20)]
    new_dialog = None
    ac  = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z','1','2','3','4','5','6','7','8','9','10','A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z']
    a = _random.choice(ac)
    b = _random.choice(ac)
    c = _random.choice(ac)
    d = _random.choice(ac)
    f = _random.choice(ac)
    g = _random.choice(ac)
    h = _random.choice(ac)
    token = a + b + c + d + f + g + h
    notdialog = None
    dialog =None
    dialoge = None
    asyncimage = None
    def build(self):
        dialog = None
        self.title = "ReviewinApp"
        self.theme_cls.theme_style = "Light"
        global sm 
        sm = ScreenManager()
        sm.add_widget(Builder.load_file("splash.kv"))
        sm.add_widget(Builder.load_file("accueil.kv"))
        sm.add_widget(Builder.load_file('conditions.kv'))
        sm.add_widget(Builder.load_file("register.kv"))
        sm.add_widget(Builder.load_file("faq.kv"))
        sm.add_widget(Builder.load_file("login.kv"))
        sm.add_widget(Builder.load_file("User2.kv"))
        sm.add_widget(Builder.load_file("rules.kv"))
        sm.add_widget(Builder.load_file("commentinput.kv"))
        sm.add_widget(Builder.load_file("UserInfo.kv"))
        sm.add_widget(Builder.load_file("recaptcha.kv"))
        sm.add_widget(Builder.load_file("contact_true.kv"))
        sm.add_widget(Builder.load_file('myinfo.kv'))
        sm.add_widget(Builder.load_file('sign_in_1.kv'))
        sm.add_widget(Builder.load_file('test.kv'))
        return sm

Code of the screen where RecycleView not appearing.

MDScreen:
    name: 'recycleview'
    md_bg_color: 41/255, 34/255, 34/255, 1
    viewclass: 'Button'
    RecycleView:
        data: app.data
        md_bg_color: 41/255, 34/255, 34/255, 1
        default_size: None, 1000
        default_size_hint: 1, None
        size_hint_y: None
        orientation: 'vertical'

Thanks for answering !

ApuCoder
  • 2,795
  • 2
  • 3
  • 19
  • It seems that you are not using [`RecycleView`](https://kivy.org/doc/stable/api-kivy.uix.recycleview.html#module-kivy.uix.recycleview) properly. – ApuCoder Oct 29 '22 at 20:39
  • Yes but how do I do in my case, I don't understand. @ApuCoder –  Oct 30 '22 at 06:59
  • Try posting a [minimal reproducible example](https://stackoverflow.com/help/minimal-reproducible-example). – ApuCoder Oct 30 '22 at 10:49
  • @ApuCoder what do you mean ? My problem is that there is nothing on the screen where recycle view is and I don't Know how to fix it. –  Oct 30 '22 at 11:36

0 Answers0