Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 89864

Xamarin Forms TableView Color Binding doesnt work

$
0
0

hi,

I'm building an interface for a settings page of an app. Currently I am at the themes of the app. Everything works very well. The colors are exchanged automatically against the new ones (header, text, etc.). For the individual setting points I use the TableView element on the basis of an example. However, the colors of the TableView are not changed when the theme is changed. I can't find a solution. Can anyone help?

The XAML of the page:

<ContentPage.Content>

    <StackLayout BackgroundColor="{DynamicResource StackLayoutBackgroundColor}">

        <TableView Intent="Settings"
                   BackgroundColor="{DynamicResource TableViewBackgroundColor}">

            <TableRoot>

                <TableSection TextColor="{DynamicResource TableViewTitleForegroundColor}" Title="Darstellung">

                    <SwitchCell On="true" Text="Moderner Feed" OnColor="{DynamicResource PrimaryColor}" />

                    <ViewCell>
                        <StackLayout
                            Padding="15,0,20,0"
                            Orientation="Horizontal"
                            VerticalOptions="Center">
                            <StackLayout.GestureRecognizers>
                                <TapGestureRecognizer NumberOfTapsRequired="1"
                                                      Tapped="Handle_Tapped" />
                            </StackLayout.GestureRecognizers>

                            <Label Text="Theme" XAlign="Center" />
                            <Label
                                HorizontalOptions="EndAndExpand"
                                Text="&gt;"
                                XAlign="Center" />
                        </StackLayout>
                    </ViewCell>

                </TableSection>

            </TableRoot>

        </TableView>

    </StackLayout>

</ContentPage.Content>

kind regards


Viewing all articles
Browse latest Browse all 89864

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>