Is is possible implement "Search" function on RadSchedulerNavigator ?

4 posts, 0 answers
  1. Eugene
    Eugene avatar
    3 posts
    Member since:
    Jun 2009

    Posted 12 May 2011 Link to this post

    Hi,

    Just want check with you guys, is it possible implement "Search" functionon RadSchedulerNavigator ? For example, search by "Subject"

    Peter
  2. Ivan Todorov
    Admin
    Ivan Todorov avatar
    688 posts

    Posted 17 May 2011 Link to this post

    Hello Vee Tian,

    Thank you for your question.

    Yes, it is possible to implement search function. You should override the RadSchedulerNavigator class and add the search logic to it. Here is an example of how this could be achieved:

    public class MySchedulerNavigator : RadSchedulerNavigator
    {
        private RadTextBox searchTextBox;
     
        public MySchedulerNavigator() : base()
        {
            searchTextBox = new RadTextBox();
            searchTextBox.Size = new Size(200, 20);
            searchTextBox.Location = new Point(400, 42);
     
            this.Controls.Add(this.searchTextBox);
              
            this.searchTextBox.KeyDown += new KeyEventHandler(searchTextBox_KeyDown);
        }
     
        void searchTextBox_KeyDown(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Enter)
            {
                FindAppointment();
            }
        }
     
        void FindAppointment()
        {
            foreach (Appointment app in this.AssociatedScheduler.Appointments)
            {
                if (app.Subject.Contains(this.searchTextBox.Text))
                {
                    this.AssociatedScheduler.ActiveView.StartDate = app.Start;
                    this.AssociatedScheduler.SchedulerElement.InvalidateMeasure(true);
                    SchedulerUIHelper.SelectAppointment(this.AssociatedScheduler, app, true);
                     
                     
                    break;
                }
            }
     
        }
     
        public override string ThemeClassName
        {
            get
            {
                return typeof(RadSchedulerNavigator).FullName;
            }
            set
            {
                base.ThemeClassName = value;
            }
        }
    }

    Currently, we do not have plans to implement built-in search functionality in RadSchedulerNavigator since you are the first one to request it. If more people request such functionality, I will log it as a feature request in our Public Issue Tracking System and we will consider implementing it in a future release.

    Should you have any additional questions, do not hesitate to contact me.

    Best wishes,
    Ivan Todorov
    the Telerik team
    Q1’11 SP1 of RadControls for WinForms is available for download; also available is the Q2'11 Roadmap for Telerik Windows Forms controls.
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Chad
    Chad avatar
    11 posts
    Member since:
    Apr 2011

    Posted 23 Aug 2011 Link to this post

    i think it would be a nice feature to have, never thought of it but it would be similar to the functionality other calendar apps (outlook, Mail in MacOS, etc) have
  5. Ivan Todorov
    Admin
    Ivan Todorov avatar
    688 posts

    Posted 25 Aug 2011 Link to this post

    Hello Chad,

    I have added your suggestion as a feature request to our Public Issue Tracking System. Please follow this link to add your vote for it and also subscribe for its status updates. We will do our best to implement it in one of our future releases.

    Feel free to share with us any suggestion you have.

    All the best,
    Ivan Todorov
    the Telerik team

    Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

Back to Top