Home > OS >  Cancelcommand is not working in sfdatepicker in xamarin forms
Cancelcommand is not working in sfdatepicker in xamarin forms

Time:10-20

I want normal cancel functionality on cancel button click of sfdatepicker footer, I am trying to achieve it by binding command but it is not working. Could any one suggest me any solution for that ?

CodePudding user response:

You can use code like below:

 <datePicker:SfDatePicker.FooterView> 
     <Grid> 
          <Button Text="Ok" 
                  x:Name="footerViewButton" 
                  Clicked="footerViewButton_Clicked"/> 
     </Grid> 
  </datePicker:SfDatePicker.FooterView> 

Created in this way, and then create the corresponding method in the ViewModel to achieve logical operations.

  • Related