We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

How to get currently selected day in monthview?

Maybe I am missing something, but how do I ask the SfSchedule what its currently selected day is in the month view?

3 Replies

SP Subburaj Pandian Veluchamy Syncfusion Team June 2, 2017 02:19 PM UTC

Hi Shawn, 
 
Thank you for contacting Syncfusion support. 
 
Based on the provided information, we suspect that your requirement is to get the Selected Date details in programmatically. As of now, the mentioned support of Programmatically getting the Selected Date details is not available in Schedule Xamarin Forms.  
 
Could you please share more details about your requirement of using this feature with the screen shot (if possible), it will be helpful for us to check on it and implement this feature in any of our upcoming volume release. 
 
Note: You get the Selected date details while selecting the specific date in Schedule using CellTapped event in Schedule, please refer the below code example 
 
[c#] 
schedule.CellTapped += Schedule_CellTapped; 
 
private void Schedule_CellTapped(object sender, CellTappedEventArgs args) 
        { 
            var DateTime = args.Datetime;   
        } 
 
 
Please let us know, if you have any query. 
 
Regards,    
Subburaj Pandian V. 



SC Shawn Castrianni June 5, 2017 05:10 AM UTC

Relying on the user to click something just to get the current state of a widget is a bad idea.  That is like requiring a user to click a button just so that I can figure out the text currently displayed on the button.  It doesn't make any sense.

I am displaying an SfSchedule and I have created a + button.  When the user clicks the + button, I create a new event to be added to the SfSchedule.  Well, I need to create the new event ON THE DATE that the SfSchedule currently has selected.  So the + button click handler needs to ask the SfSchedule what date is currently selected so that I can create a new event ON THAT DATE.


SP Subburaj Pandian Veluchamy Syncfusion Team June 6, 2017 06:58 AM UTC

Hi Shawn, 
 
Thank you for the update. 
 
Programmatically Selecting Date feature: 
As we mentioned in our previous update, programatically selecting the date support is not available in Xamarin Forms. We have already logged the feature report for the same and we will include this feature in any of our upcoming Volume release.   
 
Requirement in Sample level: 
Your requirement of adding the Appointment in the Selected date, when clicking the button can achieved in the sample level. Using CellTapped event we can get the Selected DateTime in the DateTime argument, by setting this DateTime as the Appointment DateTime in the Button Clicked event (editor) your requirement can be achieved. We have prepared based on this scenario, please find the below sample. 
 
  
Please let us know, if you have any further query on this. 
 
Regards,
Subburaj Pandian V 


Loader.
Live Chat Icon For mobile
Up arrow icon