I have a gallery that is connected to a dataverse table. In this table I have a field of type yes/no and now I want to filter the gallery so that it shows only the rows that are set to yes by a toggle. What is the best way to do this?

I have a gallery that is connected to a dataverse table. In this table I have a field of type yes/no and now I want to filter the gallery so that it shows only the rows that are set to yes by a toggle. What is the best way to do this?
Hi @alt88,
Set the Items property:
Filter(Table,Yes/No_Field=If(Toggle1.Value,'OptionName(TableName)'.Yes,'OptionName(TableName)'.No))
If you only want to filter gallery when the Toggle is true, you could use the following formula:
If(Toggle1.Value,Filter(Table,Yes/No_Field='OptionName(TableName)'.Yes),Table)