title: How can I add a tapGestureRecognizer with a parameter?
body: <p>My code currently adds this in the back end C#</p>
  
  <pre class="lang-cs prettyprint-override"><code>deselectGridLink.GestureRecognizers.Add(NewTapGestureForUpdateCategories(false));
  
      private TapGestureRecognizer NewTapGestureForUpdateCategories(bool val)
      {
          return new TapGestureRecognizer()
          {
              Command = new Command(() =&gt;
              {
                  App.DB.UpdateAllCategoryGroups(val);
                  App.DB.UpdateAllCategories(val);
                  GetPageData();
                  RemoveTableViewClickSection();
                  tableView.Root.Add(CreateTableSection());
                  SetPageDetails();
              })
          };
      }
  </code></pre>
  
  <p>How can I add this in XAML with the parameter of false also included. Also if I somehow add this to XAML do I need to change the C#f NewTapGestureForUpdateCategories method?:</p>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;Grid x:Name="deselectGridLink" VerticalOptions="CenterAndExpand" Padding="20, 0"&gt;
     &lt;Label TextColor="Blue" Style="{DynamicResource ListItemTextStyle}" x:Name="deselectLink" HorizontalOptions="StartAndExpand" VerticalOptions="Center" Text="Deselect All" /&gt;
  &lt;/Grid&gt;
  </code></pre>