Error when adding EditAppointmentDialogStyle

2 posts, 0 answers
  1. sharp
    sharp avatar
    27 posts
    Member since:
    Feb 2011

    Posted 20 Feb 2012 Link to this post

    I have this
    <ControlTemplate x:Key="EditAppointmentTemplate" TargetType="telerik:SchedulerDialog">
            <Grid  >
                    <RowDefinition Height="Auto" />
                    <RowDefinition Height="Auto" />
                    <RowDefinition Height="*" />
                    <RowDefinition Height="Auto" />
                    <RowDefinition Height="Auto" />
                    <RowDefinition Height="Auto" />
                    <RowDefinition Height="Auto" />
                    <RowDefinition Height="Auto" />
                <TextBlock Text="asdasdasdasdasdasd"/>
                <StackPanel Grid.Row="7" Margin="13 6" HorizontalAlignment="Right" Orientation="Horizontal">
                    <telerik:RadButton Margin="2" MinWidth="84" Command="telerik:WindowCommands.Confirm" telerik:LocalizationManager.ResourceKey="Ok" telerik:RadWindow.ResponseButton="Accept" >
                            <TextBlock telerik:LocalizationManager.ResourceKey="SaveAndClose" />
                    <telerik:RadButton Margin="2" MinWidth="84"  Command="telerik:WindowCommands.Cancel" telerik:LocalizationManager.ResourceKey="Cancel" telerik:RadWindow.ResponseButton="Cancel"  />
        <Style x:Key="EditAppointmentDialogStyle" TargetType="telerik:SchedulerDialog">
            <Setter Property="Foreground" Value="Black" />
            <Setter Property="Width" Value="560" />
            <Setter Property="IsTabStop" Value="False" />
            <Setter Property="Template" Value="{StaticResource EditAppointmentTemplate}" />
    <telerik:RadScheduleView Name="sv"  EditAppointmentDialogStyle="{StaticResource EditAppointmentDialogStyle}" />

    But when I add ViewDefinitions

    sv.ViewDefinitions.Add(new DayViewDefinition());

    VS tell me
    Ambiguous reference:

    When I remove from code

    EditAppointmentDialogStyle="{StaticResource EditAppointmentDialogStyle}"

    All work.
    What I do wrong?

    Sorry for wrong topic name
    it must bee

    Error when adding EditAppointmentDialogStyle
  2. Miroslav Nedyalkov
    Miroslav Nedyalkov avatar
    1718 posts

    Posted 22 Feb 2012 Link to this post


    I tried your code in an empty project and it works fine with the latest version of RadControls for Silverlight. Could you please prepare a sample project that reproduces the problem and share it with us?

    I updated the title of the thread as you suggested.

    Kind regards,
    Miroslav Nedyalkov
    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
  3. DevCraft R3 2016 release webinar banner
Back to Top