We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Syncfusion.Windows.Forms.Schedule.AppointmentForm.DisplayStrings

Thread ID:

Created:

Updated:

Platform:

Replies:

117017 Jul 20,2014 11:04 AM Jul 24,2014 02:54 PM Windows Forms 1
loading
Tags: ScheduleControl
Sergiy Tokarchuk
Asked On July 20, 2014 11:04 AM

Syncfusion.Windows.Forms.Schedule.AppointmentForm.DisplayStrings[0]="myname";
it just doesnt work i can chage whole DisplayStrings Array but the labels still has default Value ; Why?

Muthukumar Kalyanasundaram [Syncfusion]
Replied On July 24, 2014 02:54 PM

Hi Sergiy,

 

Thank you for your interest in Syncfusion products.

 

There is a static string array that holds these strings. If you want to change displaystring through this static array.

 

Here is the definition of the static member:

 

// Here we have given our display string value

 

public static string[] DisplayStrings = new string[]

                                    {

                                        "Sub&ject1:", "&Location:", "Sho&w time as:","&Reminder:", "All Day Event","En&d Time:","Start Time&:","La&bel:",   

                                        "subject", "Cancel","Save and Close",  };

        private const int _Subject1 = 0;

        private const int _Location = 1;

        private const int _Show_time_as = 2;

        private const int _Reminder = 3;

        private const int _All_Day_Event = 4;

        private const int _End_Time = 5;

        private const int _Start_Time = 6;

        private const int _Label = 7;

        private const int _subject = 8;

        private const int _Cancel = 9;

        private const int _Save_and_Close = 10;

        private const int _Enter_Appointment = 11;

       

        private void InitStrings()

        {

            this.label1.Text = DisplayStrings[_Subject];

            this.label2.Text = DisplayStrings[_Location];

            this.label6.Text = DisplayStrings[_Show_time_as];

            this.reminderCheckBox.Text = DisplayStrings[_Reminder];

            this.allDayEventCheckBox.Text = DisplayStrings[_All_Day_Event];

            this.label5.Text = DisplayStrings[_End_Time];

            this.label4.Text = DisplayStrings[_Start_Time];

            this.label3.Text = DisplayStrings[_Label];

            this.subjectTextBox.Text = DisplayStrings[_subject];

            this.button2.Text = DisplayStrings[_Cancel];

            this.button1.Text = DisplayStrings[_Save_and_Close];

            this.Text = DisplayStrings[_Enter_Appointment];

        }

 

 And to customize the Appointment from of Schedule form. The IScheduleAppointmentList is used to find the new item in ScheduleControl as shown below. 

Code Snippet:

void scheduleControl_ShowingAppointmentForm(object sender, Syncfusion.Windows.Forms.Schedule.ShowingAppointFormEventArgs e)
{
AppointMentForm fr = new AppointMentForm();
IScheduleAppointment sch = e.Item.Clone() as IScheduleAppointment;
e.Cancel = true;
e.Handled = false;
fr.schedule = this.scheduleControl;
IScheduleAppointmentList list = this.dataprovider.GetScheduleForDay(e.Item.StartTime);
if (list.Contains(e.Item))
fr.newappointment = false;
else
fr.newappointment = true;
if (fr.newappointment)
fr.SetDataProvider(dataprovider, sch);
else
{
fr.SetDataProvider(dataprovider, e.Item);
IRecurringScheduleAppointment recurItem = e.Item as IRecurringScheduleAppointment;
fr.ShowRecurDialog.Text = recurItem.RecurrenceRule.Length > 0
? (RecurrenceSupport.IsSpanItem(recurItem) ? "Delete Span" : "EditRecurring")
: "MakeRecurring";
}
fr.ShowDialog();
}

Please let us know if you have any concerns.

Thanks & Regards,

Muthukumar K

 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;