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

Change of attributes in XAML using templates

1 Answer 72 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
Thomas
Top achievements
Rank 1
Thomas asked on 22 Jan 2009, 08:22 PM

I am using the calender with templates to change buttonlayout. I am using an array of elements to define content for
every day and bind it to the button via date.DayOfYear in a switch statement.

I have some few issues:

1) It also bind to the calendars Day names lime Mon, Tue, Wed even if selecting only where DayOfYes is between 1 and 365
    Is it possible to see an attribute there shows it is not a "weekday" button ?

2) I use a grid, a picture and a border in my template. It can have lots of different scenarios and i cant create 200 different templates. Instead i want to manipulate border thickness and imagename
    I have tried with the following code in my TemplateSelector class

Border

b1 = item as Border;

 

b1.BorderThickness =

new Thickness(8);

 

and the following XAML
<Border BorderThickness="{Binding Text}" BorderBrush="{Binding Text}">

Best regards
Thomas
    

1 Answer, 1 is accepted

Sort by
0
Hristo
Telerik team
answered on 27 Jan 2009, 07:35 AM
Hi Thomas,

First sorry for the late response. I'm not sure what you want to achieve here. Could you send us a simple project (with the modified theme) with some screenshots (of what you want to achieve) so I can get a better understanding of your issues?

Thank you.

Best wishes,
Hristo
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Calendar
Asked by
Thomas
Top achievements
Rank 1
Answers by
Hristo
Telerik team
Share this question
or