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

change styles in Inline Template of radscheduler

6 Answers 110 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
MOUSLIKI
Top achievements
Rank 1
MOUSLIKI asked on 07 Mar 2011, 10:02 PM
Hi all,
      I have to change the backround of some Items in  the ComboBox sitted in Inline Template by server side code , I have used  this demo : http://demos.telerik.com/aspnet-ajax/scheduler/examples/resourceavailability/defaultcs.aspx
   But when I set for exple : ComboBox.Items[5].Background=Color.red;
the background not change and if I verify in the result I find that they use   .asx files to set style.


?????????????

6 Answers, 1 is accepted

Sort by
0
Veronica
Telerik team
answered on 10 Mar 2011, 06:57 PM
Hi MOUSLIKI,

Could you please show me your code where you are trying to change the background of the combobox?
Thank you!

Greetings,
Veronica Milcheva
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
0
MOUSLIKI
Top achievements
Rank 1
answered on 17 Mar 2011, 01:20 PM

this is my source , I need to change the backround

  for (int i = 0; i < appointmentsForSelectedHour.Count; i++)
            {

radcombo.DataSource = this.currentService.Specialists;
            radcombo.DataTextField = "Pseudo";
            radcombo.DataValueField = "id";
            radcombo.DataBind();
                if (appointmentsForSelectedHour[i].isChoosed)
                {
                    List<JCO.BusinessCore.Dbml.Specialist> AvailabaleUser = currentService.Specialists.Where(delegate(JCO.BusinessCore.Dbml.Specialist spec) { return spec.Pseudo == appointmentsForSelectedHour[i].PseudoSpecialist; }).ToList();
                    if (AvailabaleUser.Count != 0)
                    {
                        radcombo.Items[this.currentService.Specialists.IndexOf(AvailabaleUser[0])].BackColor =red;
                    }
                }
            }

           

0
MOUSLIKI
Top achievements
Rank 1
answered on 17 Mar 2011, 01:22 PM
In runnig I think that the color is changed but after making a style to all Radscheduler the color change aganu to predefined color of radscheduler
0
Veronica
Telerik team
answered on 17 Mar 2011, 02:05 PM
Hello MOUSLIKI,

I'm interested in which event yuo are trying to change the background color of the combobox? Could you please send me a runnable project and I'll try to help you?

Thank you!

Best wishes,
Veronica Milcheva
the Telerik team
0
MOUSLIKI
Top achievements
Rank 1
answered on 17 Mar 2011, 03:41 PM
Thank you

I use this code in the event AppointementCreated

0
Veronica
Telerik team
answered on 22 Mar 2011, 10:03 AM
Hi MOUSLIKI,

Could you please send me your full code so I can inspect it and help you?
Thank you!

Greetings,
Veronica Milcheva
the Telerik team
Tags
General Discussions
Asked by
MOUSLIKI
Top achievements
Rank 1
Answers by
Veronica
Telerik team
MOUSLIKI
Top achievements
Rank 1
Share this question
or