Custom Times Remove a speicifc time slot

2 posts, 0 answers
  1. Philip
    Philip avatar
    69 posts
    Member since:
    Mar 2016

    Posted 13 Mar Link to this post

    Thanks for the last reply I am not a we bit futher on I am building a custom provider list for the date times but what I have not been able to figure out is how to match dates that have already been inputed in my table i am using appointments from radsechulre i am trying to check dates in the db though that are stored in datetime values but when I try to set the custom value that you suggest here is some of my code.



    On My drop down of managers I am going out to the function as so. So What i need be able to do is set a pre definined block times and intervals and two remove any time thats been saved in the db already.



    1.protected void rdManagers_SelectedIndexChanged(object sender, Telerik.Web.UI.DropDownListEventArgs e)
    2.        {
    3.            customDatePickerProvider _timePickerValues = new customDatePickerProvider(new Guid(e.Value), Convert.ToDateTime("09:00"), Convert.ToDateTime("18:00"));
    4.            rdStarDate.TimeView.CustomTimeValues = _timePickerValues.BuildTimeList(true, new Guid(e.Value), Convert.ToDateTime("09:00"), Convert.ToDateTime("18:00"));
    5.        }
    8.public D

    01.public DateTime[] BuildTimeList(Boolean removeList, Guid managerID, DateTime startDate, DateTime endDate)
    02.      {
    03.          var q = _dal.checkDatesAvailabilty(managerID).ToList();
    04.          if (q != null)
    05.          {
    06.              DateTime[] timesForPicker = new DateTime[] { new DateTime(2012, 12, 15, 12, 10, 10), new DateTime(2012, 12, 15, 5, 6, 3), new DateTime(2012, 12, 15, 3, 8, 11) };
    08.              Array.ForEach(q.ToArray(), l =>
    10.              {
    11.                  //we want to try and parse the date out of the prenset list here we going to use the date range function to create a list of dates
    12.              });
    13.              return timesForPicker;
    14.          }
    15.          return null;
    16.      }

  2. Viktor Tachev
    Viktor Tachev avatar
    1488 posts

    Posted 14 Mar Link to this post

    Hi Philip

    i have replied to your query in the other thread you have submitted. Check out the answer by following the link below:

    Viktor Tachev
    Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top