Skip to content
Advertisement

how to insert a MDList in a MDDialog in kivyMD?

I need to show the data from a dictionary in a ThreeLineListItem inside a MDDialog, but my code doesn’t seem to work.

Here’s my code:

JavaScript

Do I need to import the values for the MDList from the KV file?

Advertisement

Answer

You can’t call your MDDialog class like : DialogContent().check_conflicts(product_dict).

You need to reach self.dialog.Because you created this with your custom settings and custom content. Otherwise, you just calling another BoxLayout which name is DialogContent. You can use self.dialog name for call your created dialog.

You need to run your check_conflicts function like that:

JavaScript
User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement