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

Custom Resource - hide from user

3 Answers 49 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Tom Kaminski
Top achievements
Rank 1
Tom Kaminski asked on 30 Jul 2009, 04:06 PM
I am developing a site that handles content based on the domain name requested.  Code in global.asax assigns a DeptID based on the domain.  In using the scheduler, I only want to show/handle appointments for this DeptID.  I think I need to treat this like a custom resource - but how do I implement that?  I see how the documentation handles Rooms and Users, but I don't want to expose DeptID for the user to make a choice, and all appointments need to be filtered/inserted/updated for this DeptID only.

3 Answers, 1 is accepted

Sort by
0
Accepted
Peter
Telerik team
answered on 31 Jul 2009, 10:51 AM
Hello Tom,

You can hide the resource dropdown and label in the advanced form using the following kb article:
http://www.telerik.com/support/kb/aspnet-ajax/scheduler/how-to-access-controls-in-the-advanced-form.aspx

Here is the specific code for your case:
protected void RadScheduler2_FormCreated(object sender, SchedulerFormCreatedEventArgs e)  
    {  
        if (e.Container.Mode == SchedulerFormMode.AdvancedEdit || e.Container.Mode == SchedulerFormMode.AdvancedInsert)  
        {  
            RadComboBox resComboBox = e.Container.FindControl("ResDeptID"as RadComboBox;  
            resComboBox.Visible = false;  
 
            WebControl resLabel = e.Container.FindControl("LblResDeptID"as WebControl;  
            resLabel.Controls.Clear();  
        }  
    } 



Kind regards,
Peter
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Tom Kaminski
Top achievements
Rank 1
answered on 31 Jul 2009, 04:03 PM
Thanks Peter!

I'm actually learning how to customize the advanced template.
http://www.telerik.com/help/aspnet-ajax/schedule_advancedformtemplate.html
0
Peter
Telerik team
answered on 03 Aug 2009, 05:40 AM
Hi Tom,

I can see where the confusion comes from. Just to clarify, the help topic which you have seen shows how to use templates to customize the advanced form, while the kb article I referred you to, shows how to customize the default advanced form. Anyway, I am glad to learn that this is sorted out for you.


Greetings,
Peter
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
Scheduler
Asked by
Tom Kaminski
Top achievements
Rank 1
Answers by
Peter
Telerik team
Tom Kaminski
Top achievements
Rank 1
Share this question
or