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

[Solved] Unhandled exception and application crash after update to 2012.2 607

2 Answers 103 Views
ListPicker
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
OTMOP
Top achievements
Rank 2
OTMOP asked on 13 Jun 2012, 07:03 AM
Hello.

First of all sorry for my bad english.

In my app I have a style for RadListPicker.

<Style TargetType="telerikInput:RadListPicker">
        <Setter Property="PopupStyle">
            <Setter.Value>
                <Style TargetType="telerikPrimitives:RadSelector">
                    <Setter Property="Foreground" Value="{StaticResource ForegroundBrush}" />
                    <Setter Property="Background" Value="{StaticResource ChromeBrush}"/>
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="HeaderStyle">
            <Setter.Value>
                <Style TargetType="ContentControl">
                    <Setter Property="HorizontalAlignment" Value="Left" />
                    <Setter Property="VerticalAlignment" Value="Center" />
                    <Setter Property="FontSize" Value="{StaticResource PhoneFontSizeNormal}" />
                    <Setter Property="Foreground" Value="{StaticResource LightAccentForegroundBrush}" />
                    <Setter Property="Margin" Value="0, 0, 0, 8" />
                </Style>
            </Setter.Value>
        </Setter>
    </Style>

All custom resources (brushes, colors, etc) are declared. This style worked perfect in 2012.1 321 version, but after update to 2012.2 607 my app is crashing in runtime with following exceptions:

A first chance exception of type 'System.Windows.Markup.XamlParseException' occurred in System.Windows.dll
A first chance exception of type 'System.Exception' occurred in System.Windows.dll
A first chance exception of type 'MS.Internal.WrappedException' occurred in System.Windows.dll
A first chance exception of type 'MS.Internal.WrappedException' occurred in System.Windows.dll
A first chance exception of type 'MS.Internal.WrappedException' occurred in System.Windows.dll
A first chance exception of type 'MS.Internal.WrappedException' occurred in System.Windows.dll


It seems that problem is in PopupStyle declaration. If I remove it then application works well, but I need PopupStyle. Any ideas?

2 Answers, 1 is accepted

Sort by
0
Accepted
Valentin.Stoychev
Telerik team
answered on 13 Jun 2012, 12:01 PM
Hello,

We are aware of this change and it is documented as a breaking change in our release notes for Q2.2012.
If you use custom style for the ListPicker PopupStyle you should change it to be similar to this:

<Setter Property="PopupStyle">

<Setter.Value>

<Style TargetType="telerikPrimitives:RadDataBoundListBox">

<Setter Property="FontSize" Value="{StaticResource PhoneFontSizeExtraLarge}" />

<Setter Property="FontFamily" Value="{StaticResource PhoneFontFamilySemiLight}" />

<Setter Property="Background" Value="{StaticResource PhoneChromeBrush}" />

<Setter Property="HorizontalAlignment" Value="Stretch" />

<Setter Property="VerticalAlignment" Value="Stretch" />

<Setter Property="CheckBoxStyle">

<Setter.Value>

<Style TargetType="telerikPrimitives:ItemCheckBox">

<Setter Property="VerticalAlignment" Value="Center" />

</Style>

</Setter.Value>

</Setter>

</Style>

</Setter.Value>

</Setter>




Greetings, Valentin.Stoychev
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
OTMOP
Top achievements
Rank 2
answered on 14 Jun 2012, 07:31 AM
Thank you, Valentin. This solution works fine.
Tags
ListPicker
Asked by
OTMOP
Top achievements
Rank 2
Answers by
Valentin.Stoychev
Telerik team
OTMOP
Top achievements
Rank 2
Share this question
or