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

Remove Fields From Custom Appointment Dialog

5 Answers 175 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Ian Scholz
Top achievements
Rank 1
Ian Scholz asked on 13 May 2010, 06:30 PM

Hello:

I have seen plenty of posts, webinar and code examples detailing how to add custom fields to an inherited class of the Appointment dialog used with RadScheduler. What I would like to know is the reverse of adding custom fields; How do I remove fields from an inherited or derived class of the Appointment dialog. If I remove some of the default fields from the inherited form, will that cause unintended problems because I simply removed the unwanted fields from the form? Or is there a simpler way of hiding the form files by the way of property dialogs on the RadScheduler control, or should I simply hide (make the fields non visible) on the inherited form from the Appointment dialog?

Thanks!

5 Answers, 1 is accepted

Sort by
0
Dobry Zranchev
Telerik team
answered on 14 May 2010, 01:48 PM
Hello Ian Scholz,

Thank you for writing.

There is no better way to just hide the controls in the form. The other way is to create a custom form from scratch and perform this manually.

If you have other questions do no hesitate to contact us.

Kind regards,
Dobry Zranchev
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
0
Ian Scholz
Top achievements
Rank 1
answered on 14 May 2010, 04:36 PM
Ok.  So I inherited from EditAppointmentDialog class and was able to hide the controls I did not want visible on the form but I'm not able to hide the associated labels;  At runtime the unwanted controls are not visible, but the associated labels are. 

Also, all the properties are disabled for the label controls and are locked so I cannot hide or delete the them.  

Additionally, I tried to set the title of the dialog to something other than the default but when the dialog is visible in the running application, I get the default title for my custom Appointment dialog.  How do I override this behavior?

Thanks!
0
Dobry Zranchev
Telerik team
answered on 17 May 2010, 03:55 PM
Hi Ian Scholz,

Thank for writing back to me.

You are right about the labels and the other controls - we will unlock these in the next major release in order to allow for removing them. Please, excuse us for the inconvenience.

You can change the EditAppointmentDialog title by:

1. Creating a class that inherits RadSchedulerLocalizationProvider and overrides its method GetLocalizationString:
 
class CustomLocalization : RadSchedulerLocalizationProvider
{
    public override string GetLocalizedString(string id)
    {
        if (id == RadSchedulerStringId.AppointmentDialogTitle)
            return "custom title";
        return base.GetLocalizedString(id);
    }
}
 
The class RadSchedulerStringId contains all string constants that are represented in the scheduler. To change the title of the EditAppointmentDialog return a different value only if the requested id is
AppointmentDialogTitle, otherwise call the base method.
 
2. Set the new localization provider to be the default provider:
 
RadSchedulerLocalizationProvider.CurrentProvider = new CustomLocalization();

I hope this will help you.

Sincerely yours,
Dobry Zranchev
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
0
Sina
Top achievements
Rank 1
answered on 01 Jul 2018, 02:54 PM
Could you help me about how i can design an edit appointment dialog from the scratch? 
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 02 Jul 2018, 11:31 AM
Hello, Sina,    

The following help article is quite useful on this topic: https://docs.telerik.com/devtools/winforms/scheduler/dialogs/editappointmentdialog

I hope this information helps. If you have any additional questions, please let me know. 
 
Regards,
Dess
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Scheduler and Reminder
Asked by
Ian Scholz
Top achievements
Rank 1
Answers by
Dobry Zranchev
Telerik team
Ian Scholz
Top achievements
Rank 1
Sina
Top achievements
Rank 1
Dess | Tech Support Engineer, Principal
Telerik team
Share this question
or