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

RadScheduler Change Text of Labels

5 Answers 254 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Jahangeer
Top achievements
Rank 1
Jahangeer asked on 12 Aug 2015, 10:59 AM

How can I change builtin text of RadScheduler from Subject=> Description, StartTime => Start Date, EndTime=> EndDate and how can I hide checkbox of AllDay and Recurrence.

 I had also tried inside OnFormCreated event

           CheckBox AllDayEvent = (CheckBox)e.Container.FindControl("AllDayEvent");
                  AllDayEvent.Visible=false;
                  RadTimePicker StartTime = (RadTimePicker)e.Container.FindControl("StartTime");
                  RadTimePicker EndTime = (RadTimePicker)e.Container.FindControl("EndTime");
                  StartTime.Visible = false;
                  EndTime.Visible = false;

but after this code save button does not work. 

Can I set the height of Subject box? You can easily understand my questions in attached image.

Please find attached image.​

Thanks

5 Answers, 1 is accepted

Sort by
0
Ivan Danchev
Telerik team
answered on 14 Aug 2015, 03:01 PM
Hello,

The following changes (highlighted) have to be made to AdvancedForm.ascx in order to change the labels Text:

1. Subject=> Description:
<telerik:RadTextBox runat="server" ID="SubjectText" Width="100%" LabelCssClass="rfbLabel"
    Label='Description' />

2. StartTime => Start Date:
<label class="rfbLabel" for='<%= StartDate.ClientID %>_dateInput_text'>
    StartDate</label>

3. EndTime=> EndDate:
<label class="rfbLabel" for='<%= EndDate.ClientID %>_dateInput_text'>
    EndDate</label>

4. You can hide the AddDay and Recurrence check boxes with the following two CSS rules:
html .RadScheduler .rsAllDayWrapper {
    visibility: hidden;
}
 
html .RadScheduler .rsAdvChkWrap {
    visibility: hidden;
}

5. The subject box' height can be set with the following rule:
html .RadScheduler .riContentWrapper > input {
    height: 100px;
}

Regards,
Ivan Danchev
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
0
Jahangeer
Top achievements
Rank 1
answered on 15 Aug 2015, 06:39 AM
This might be stupid question, how to open AdvancedForm.ascx I don't have any form like this in my project :( 
0
Ivan Danchev
Telerik team
answered on 18 Aug 2015, 12:27 PM
Hello,

Another way to change these labels is to set their corresponding RadScheduler Localization properties:
<telerik:RadScheduler runat="server" ID="RadScheduler1" Localization-AdvancedSubject="Description" Localization-AdvancedFrom="StartDate" Localization-AdvancedTo="EndDate">

This will work even if you do not use the AdvancedForm UserControl in your project.

Regards,
Ivan Danchev
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
0
Jahangeer
Top achievements
Rank 1
answered on 22 Aug 2015, 09:26 AM
Thanks for your answer but one thing remained how can I change the height of subject textbox and limit characters max upto 256 I mean something like maxlenth??
0
Ivan Danchev
Telerik team
answered on 25 Aug 2015, 02:51 PM
Hello,

You can set the Subject TextBox' MaxLength property in the Scheduler's FormCreated event handler:
protected void RadScheduler1_FormCreated(object sender, SchedulerFormCreatedEventArgs e)
{
    if (e.Container.Mode == SchedulerFormMode.AdvancedInsert || e.Container.Mode == SchedulerFormMode.AdvancedEdit )
    {
        RadTextBox subject = (RadTextBox)e.Container.FindControl("Subject");
        subject.MaxLength = 10;
    }
}

For this to work on appointment insertion the StartInsertingInAdvancedForm property has to be set to "true".

The subject box' height can be changed with the CSS rule I posted in my previous reply, however this would only be a visual change and text would still be possible to enter only on a single line, since the Subject textbox renders as an input element.

Regards,
Ivan Danchev
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
Asked by
Jahangeer
Top achievements
Rank 1
Answers by
Ivan Danchev
Telerik team
Jahangeer
Top achievements
Rank 1
Share this question
or