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

Focused Element RadScheduler

3 Answers 149 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Chris Holmes
Top achievements
Rank 1
Chris Holmes asked on 13 Jun 2011, 03:32 PM

Here's the situation,

I'm trying to focus an appointment in the scheduler control but it's not possible to cast an appointment object to a radelement which is the type asked for the method FocusedElement.
Here's the code:
              foreach (Appointment app in ModificationsScheduler.Appointments)
              {
                  cAppointment = (CustomAppointment)app;
                     if (containsString(cAppointment.Summary.ToString(), strIndex, StringComparison.Ordinal) == true)
                     {
                         this.ModificationsScheduler.FocusedElement = app;
                     }
                    
              }

Is there any way to do this?

Thanks,

3 Answers, 1 is accepted

Sort by
0
Ivan Todorov
Telerik team
answered on 16 Jun 2011, 08:48 AM
Hi Chris Holmes,

Thank you for your question.

The objects of type Appointment are logical objects that represent an appointment and they are attached to visual items of type AppointmentElement which you are able to cast to RadElement since they inherit from it. Here is a code snippet that demonstrates how you can get the visual elements and focus the desired one:

foreach (AppointmentElement appElement in SchedulerUIHelper.GetAppointmentElements(ModificationsScheduler))
{
    IEvent app = appElement.Appointment;
    cAppointment = (CustomAppointment)app;
    if (containsString(cAppointment.Summary.ToString(), strIndex, StringComparison.Ordinal) == true)
    {
        this.ModificationsScheduler.FocusedElement = appElement;
    }
}

Hope this helps. Feel free to ask if you have any additional questions.

Regards,
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
Chandz
Top achievements
Rank 2
answered on 03 Feb 2016, 02:49 PM
Hello Telerik team,

 I have a Radscheduler and an individual button, in a web form in my aspx page(c# and Asp.net).

when in week view of the scheduler, it displays the first week (i.e)  jan 3 2016 sunday to jan 9 2016 saturday,

i want to view the next week on button click (i.e)  jan 10 2016 sunday to jan 16 2016 saturday,

telerik has dayview, weekview, monthview, agendaview and timelineview but not nextweekview.

but next week can be viewed by clicking the right navigation arrow in the top left of the scheduler.

is the same functionality possible with a button to show next week.

Googling does not help me in this case.

 

Thanks in advance..

Hope you people reply a bit faster.
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 03 Feb 2016, 03:42 PM

Hello ,

Thank you for writing.

I would like to note that this forum is related to the Telerik UI for WinForms suite. However, your question seems to be connected with the ASP.NET product. Feel free to post your question in the relevant forum: http://www.telerik.com/forums

I hope this information helps. Should you have further questions I would be glad to help.

Regards,
Dess
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Scheduler and Reminder
Asked by
Chris Holmes
Top achievements
Rank 1
Answers by
Ivan Todorov
Telerik team
Chandz
Top achievements
Rank 2
Dess | Tech Support Engineer, Principal
Telerik team
Share this question
or