Bind Selected Appointment from ScheduleView to Local Variable

3 posts, 0 answers
  1. Abdulaziz
    Abdulaziz avatar
    8 posts
    Member since:
    Jun 2013

    Posted 29 Jun 2014 Link to this post

    •  Hi,,
      Am Using MVVM  ,
      Is It Possible to bind Selected Appointment  from Schedulview to local Variable.

      I try the Following Code ,

      in xaml
      SelectedAppointments="{Binding MyAppointments}" >

      in ViewModel

      private Appointment _MyAppointments;
      publicAppointment  MyAppointments
      {    get { return _MyAppointments; } 
         set    {  if (value  ==  _MyAppointments)
           _MyAppointments =value;   
      on propertychanged("MyAppointments");

      dim DateFrom as datetime= MyAppointments.start();
      dim DateTo as datetime= MyAppointments.End();

  2. Abdulaziz
    Abdulaziz avatar
    8 posts
    Member since:
    Jun 2013

    Posted 01 Jul 2014 in reply to Abdulaziz Link to this post

     I solve it Guys ;

    i write In xaml 

    SelectedSlot"{Binding SelectedAppoint,Mode=TwoWay}"

    and then in VM 

    private Slot _SelectedAppoint;
    public Slot  SelectedAppoint
    {    get { return _SelectedAppoint; } 
       set    {  if (value  ==  _SelectedAppoint)
         _SelectedAppoint =value;   
    on propertychanged("SelectedAppoint");
    and then you can Use SelectedAppoint.start ...etc.
    the main thing you have to do is TwoWay binding in SelectedSlot.

  3. Kalin
    Kalin avatar
    1283 posts

    Posted 01 Jul 2014 Link to this post

    Hi Abdulaziz,

    We are glad you have managed to achieve the desired. However you should be able to bind the SelectedAppointment as well as the SelectedSlot properties of the ScheduleView without a problem. If you have any further issues, let us know.

    Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
Back to Top