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

Shape

1 Answer 36 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Samuel
Top achievements
Rank 1
Samuel asked on 08 Nov 2010, 12:48 PM
I'm trying to insert a Rectangle as a RadComboxItem using the following XAML code:

<telerik:RadComboBox Grid.Row="1" Grid.Column="1" Height="25" Margin="5,0,0,0" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch">
    <telerik:RadComboBoxItem>
        <Rectangle Margin="2" HorizontalAlignment="Stretch" Height="15">
            <Rectangle.Fill>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <LinearGradientBrush.RelativeTransform>
                        <CompositeTransform CenterY="0.5" CenterX="0.5" Rotation="90"/>
                    </LinearGradientBrush.RelativeTransform>
                    <GradientStop Color="Red"/>
                    <GradientStop Color="Blue" Offset="1"/>
                    <GradientStop Color="Lime" Offset="0.5"/>
                </LinearGradientBrush>
            </Rectangle.Fill>
        </Rectangle>
    </telerik:RadComboBoxItem>
</telerik:RadComboBox>

The Rectangle appears normally when I click to open the RadComboBox (in list), but when selected (the list closes) it disappears from the closed RadComboBox.

How can I solve this?

Thanks.

1 Answer, 1 is accepted

Sort by
0
Konstantina
Telerik team
answered on 10 Nov 2010, 08:36 AM
Hello Samuel,

Thank you for contacting us.

You can try setting the SelectionBoxTemplate. You can find more information in this help article: http://www.telerik.com/help/silverlight/radcombobox-populating-with-data-selectionbox.html

Hope this information helps. Please let us know if you have any other questions.

All the best,
Konstantina
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
ComboBox
Asked by
Samuel
Top achievements
Rank 1
Answers by
Konstantina
Telerik team
Share this question
or