title: Method binding or other solutions XAML/UWP
body: <p>I have ItemTemplate binded  to my class. The class has a method which returns a SolidColorBrush. How i can bind it to XAML? The class is serialized so I can not just make the SolidColorBrush variable. </p>
  
  <p>XAML</p>
  
  <pre><code>&lt;GridView.ItemTemplate&gt;
      &lt;DataTemplate x:DataType="local:GetRem" &gt;
          &lt;Grid Margin="-2,-5,-6,0"  HorizontalAlignment="Stretch" Background="{x:Bind GetColor}"&gt;
  </code></pre>
  
  <p>С#</p>
  
  <pre><code>public SolidColorBrush GetColor()
      {
          string ColorName = ReminderColor;
          Color Getit;
          if (ColorName == "1")
              Getit = Color.FromArgb(255, 135, 136, 0);
          else
              if (ColorName == "2")
                  Getit = Color.FromArgb(177, 237, 237, 0);
              else
                  if (ColorName == "3")
                      Getit = Color.FromArgb(214, 243, 153, 0);
                  else
                      if (ColorName == "4")
                          Getit = Color.FromArgb(254, 243, 153, 0);
          SolidColorBrush TestBrush = new SolidColorBrush(Getit);
          return TestBrush;
  
      }     
  </code></pre>