This is a migrated thread and some comments may be shown as answers.

Is is possible implement "Search" function on RadSchedulerNavigator ?

3 Answers 87 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Zujiang
Top achievements
Rank 1
Zujiang asked on 12 May 2011, 07:15 AM
Hi,

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

Peter

3 Answers, 1 is accepted

Sort by
0
Ivan Todorov
Telerik team
answered on 17 May 2011, 03:30 PM
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.
0
Chad
Top achievements
Rank 1
answered on 23 Aug 2011, 06:45 AM
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
0
Ivan Todorov
Telerik team
answered on 25 Aug 2011, 04:04 PM
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 >>

Tags
Scheduler and Reminder
Asked by
Zujiang
Top achievements
Rank 1
Answers by
Ivan Todorov
Telerik team
Chad
Top achievements
Rank 1
Share this question
or