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

Displaying elements other than appointments on the scheduler?

9 Answers 80 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Rex Chappell
Top achievements
Rank 1
Rex Chappell asked on 29 Sep 2008, 03:51 PM
Is it possible to display a custom control on the scheduler in addition to the default appointment functionality? This could be as simple as a label or an image for my purposes.

9 Answers, 1 is accepted

Sort by
0
T. Tsonev
Telerik team
answered on 30 Sep 2008, 11:36 AM
Hi,

It depends on exactly where you want to place the controls. You can use the AppointmentTemplate to customize the appointments themselves. Also, in the upcoming Service Pack 2 (to be released this week), we will support adding controls to the time slots themselves by means of the TimeSlotCreated event. We can provide you with example if you can describe us your scenario with a bit more detail.

All the best,
Tsvetomir Tsonev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Paige Cook
Top achievements
Rank 2
answered on 02 Oct 2008, 07:29 PM
I would be interested in seeing an example that would insert an image into a timeslot. Our users have asked for the ability to insert a note at a specified time of the day for a resource. So I would like to insert an image into the appropriate timeslot that would have the alt attribute set to the note text (or have hovering over the image display a RadToolTip).$0$0$0$0Thanks!$0
0
debbie f
Top achievements
Rank 1
answered on 03 Oct 2008, 03:43 PM
Is this supposed to be a feature in 2008.2.1001.20?  It seems like the only way to add controls to the timeslot is  e.TimeSlot.FormContainer.Controls.Add.  FormContainer is always null so I can't seem to add a label (or whatever control I'd like to insert). 

Is there another way?  I have some very complicated calculations that happen on a per day basis that are not appointments. I need to run these against my db during the OnTimeSlotCreated event, so I need to be able to add controls where appropriate.
0
T. Tsonev
Telerik team
answered on 03 Oct 2008, 04:13 PM
Hi,

Adding controls is in fact possible through the TimeSlotCreated event:

protected void RadScheduler1_TimeSlotCreated(object sender, TimeSlotCreatedEventArgs e) 
    e.TimeSlot.Control.Controls.Add(new LiteralControl("test")); 
 

There is a little catch, though. Controls added here will not fire events, as the TimeSlotCreated is not fired on time after postback. Unfortunately, fixing this was not possible in the SP release, as it will lead to a breaking change (the TimeSlotCreated event will be fired twice). So we have decided to include this functionality in Q3. Images, will be fine though.

Sincerely yours,
Tsvetomir Tsonev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Rex Chappell
Top achievements
Rank 1
answered on 06 Oct 2008, 03:28 PM
Hi,

I'm working in VB.net and the e.TimeSlot object doesn't seem to have a "Control" property. "FormContainer"doesn't seem to work, and "Appointments" doesn't seem to be what I need either. Any suggestions?
0
jason
Top achievements
Rank 1
answered on 06 Oct 2008, 03:31 PM
e.TimeSlot.Control doesn't show up in intellisense, but it does build and work as  Tsvetomir suggested.  I am able to get labels to show up where I need them using this method.
0
Rex Chappell
Top achievements
Rank 1
answered on 06 Oct 2008, 03:32 PM
It's actually tossing me an error when I try to compile saying that Control isn't a member of ISchedulerTimeSlot
0
T. Tsonev
Telerik team
answered on 07 Oct 2008, 11:17 AM
Hi Rex,

Can you please confirm that you are using the latest version of the assembly? It should be 2008.2.1001.

Best wishes,
Tsvetomir Tsonev
0
Rex Chappell
Top achievements
Rank 1
answered on 07 Oct 2008, 02:07 PM
In fact I am not. I currently have 2008.1.619. I'll update and try again.
Tags
Scheduler
Asked by
Rex Chappell
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
Paige Cook
Top achievements
Rank 2
debbie f
Top achievements
Rank 1
Rex Chappell
Top achievements
Rank 1
jason
Top achievements
Rank 1
Share this question
or