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

Can't change the value of a ContentView, not even use Binding...

$
0
0

I'm using a component with inheritance from ContentView, but i can't change his value with the code behind, not event use Binding to change his value.

XAML:

                          <bp:AutoCompleteView
                                      x:Name="autocomplete"
                                      Text="{Binding Name, Mode=TwoWay}"
                                      Suggestions="{Binding Items, Mode=TwoWay}"
                                      ShowSearchButton="False"
                                      SearchBackgroundColor="White"
                                      SuggestionBackgroundColor="White"
                                      SearchCommand="{Binding SearchCommand}"
                                      SelectedItem="{Binding SelectedItem}"
                                      SelectedCommand="{Binding CellSelectedCommand}"
                                      Placeholder="Place Holder Test"
                                  />

XAML.CS:

if (Application.Current.Properties.ContainsKey("Url"))
{
Name = Application.Current.Properties["Url"].ToString();
autocomplete.Text = Name;
}

Someone have any idea why ?


Viewing all articles
Browse latest Browse all 91519

Trending Articles



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