Drop Down does not close.

4 posts, 0 answers
  1. Yogendra
    Yogendra avatar
    17 posts
    Member since:
    Aug 2013

    Posted 04 Sep 2013 Link to this post

    Hi,

    i am working with RadDiagram and customizing the Style Tab of  setting Pane using this code :-
    <telerik:RadComboBox telerik:SettingsPaneView.EditorItemType="Shapes, Connections"
                                                         telerik:SettingsPaneView.EditorPropertyName="StrokeDashArray"
                                                         telerik:SettingsPaneView.EditorValue="{Binding SelectedItem,
                                                                                                        Mode=TwoWay,
                                                                                                        RelativeSource={RelativeSource Self}}">
                                        <telerik:RadComboBox.ItemTemplate>
                                            <DataTemplate>
                                                <Grid Width="140" Height="20">
                                                    <Path Margin="5"
                                                          VerticalAlignment="Center"
                                                          Data="M0,0L215,0"
                                                          Fill="{Binding Foreground,
                                                                         RelativeSource={RelativeSource FindAncestor,
                                                                                                        AncestorLevel=1,
                                                                                                        AncestorType=ContentControl}}"
                                                          Stroke="{Binding Foreground,
                                                                           RelativeSource={RelativeSource FindAncestor,
                                                                                                          AncestorLevel=1,
                                                                                                          AncestorType=ContentControl}}"
                                                          StrokeDashArray="{Binding}" />
                                                </Grid>
                                            </DataTemplate>
                                        </telerik:RadComboBox.ItemTemplate>
                                        <telerik:RadComboBox.SelectionBoxTemplate>
                                            <DataTemplate>
                                                <Grid Width="140" Height="20">
                                                    <Path Margin="5"
                                                          VerticalAlignment="Center"
                                                          Data="M0,0L215,0"
                                                          Fill="{Binding Foreground,
                                                                         RelativeSource={RelativeSource FindAncestor,
                                                                                                        AncestorLevel=1,
                                                                                                        AncestorType=ContentControl}}"
                                                          Stroke="{Binding Foreground,
                                                                           RelativeSource={RelativeSource FindAncestor,
                                                                                                          AncestorLevel=1,
                                                                                                          AncestorType=ContentControl}}"
                                                          StrokeDashArray="{Binding}" />
                                                </Grid>
                                            </DataTemplate>
                                        </telerik:RadComboBox.SelectionBoxTemplate>


    But using this code, when change the selection of Border combo box, drop down is open , and select item then drop down does not colse
    and selected item is not show in combo box. 

    Please suggest me something.
    Thanks in advanced.


  2. Petar Mladenov
    Admin
    Petar Mladenov avatar
    2891 posts

    Posted 09 Sep 2013 Link to this post

    Hi Yogendra,

    First, I wonder why the RadComboBox has no ItemsSource set. I used the following code:

                                        <telerik:RadComboBox telerik:SettingsPaneView.EditorItemType="Shapes, Connections"
                                                         telerik:SettingsPaneView.EditorPropertyName="StrokeDashArray"
                                                             ItemsSource="{data:StrokeDashArray}"
                                                         telerik:SettingsPaneView.EditorValue="{Binding SelectedItem,
                                                                                                        Mode=TwoWay,
                                                                                                        RelativeSource={RelativeSource Self}}">
                                            <telerik:RadComboBox.ItemTemplate>
    ....
    and everything worked successfully. Could you please check it out in our test project and let us know if it helps you proceed further? Regards,
    Petar Mladenov
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  3. DevCraft banner
  4. Yogendra
    Yogendra avatar
    17 posts
    Member since:
    Aug 2013

    Posted 13 Sep 2013 Link to this post

    Thanks for reply back.

    But it's not working.when i am running your project , application gets creches, unable to find the issue. I am using same xaml as in your demo.project. But it still not working. here is my code:-

    <telerik:RadComboBox telerik:SettingsPaneView.EditorItemType="Shapes, Connections"
                                                                   telerik:SettingsPaneView.EditorPropertyName="StrokeDashArray"
                                                                   ItemsSource="{data:StrokeDashArray}"
                                                                   telerik:SettingsPaneView.EditorValue="{Binding SelectedItem,
                                                                                                      Mode=TwoWay,
                                                                                                      RelativeSource={RelativeSource Self}}">
                                                  <telerik:RadComboBox.ItemTemplate>
                                                      <DataTemplate>
                                                          <Grid Width="140"
                                                                Height="20">
                                                              <Path Margin="5"
                                                                    VerticalAlignment="Center"
                                                                    Data="M0,0L215,0"
                                                                    Fill="{Binding Foreground,
                                                                       RelativeSource={RelativeSource FindAncestor,
                                                                                                      AncestorLevel=1,
                                                                                                      AncestorType=ContentControl}}"
                                                                    Stroke="{Binding Foreground,
                                                                         RelativeSource={RelativeSource FindAncestor,
                                                                                                        AncestorLevel=1,
                                                                                                        AncestorType=ContentControl}}"
                                                                    StrokeDashArray="{Binding}" />
                                                          </Grid>
                                                      </DataTemplate>
                                                  </telerik:RadComboBox.ItemTemplate>
                                                  <telerik:RadComboBox.SelectionBoxTemplate>
                                                      <DataTemplate>
                                                          <Grid Width="140"
                                                                Height="20">
                                                              <Path Margin="5"
                                                                    VerticalAlignment="Center"
                                                                    Data="M0,0L215,0"
                                                                    Fill="{Binding Foreground,
                                                                       RelativeSource={RelativeSource FindAncestor,
                                                                                                      AncestorLevel=1,
                                                                                                      AncestorType=ContentControl}}"
                                                                    Stroke="{Binding Foreground,
                                                                         RelativeSource={RelativeSource FindAncestor,
                                                                                                        AncestorLevel=1,
                                                                                                        AncestorType=ContentControl}}"
                                                                    StrokeDashArray="{Binding}" />
                                                          </Grid>
                                                      </DataTemplate>
                                                  </telerik:RadComboBox.SelectionBoxTemplate>
     
                                                  <DoubleCollection>1 3</DoubleCollection>
                                                  <DoubleCollection>4 4</DoubleCollection>
                                                  <DoubleCollection>10 10</DoubleCollection>
                                                  <DoubleCollection>15 15</DoubleCollection>
                                                  <DoubleCollection>2 10</DoubleCollection>
                                                  <DoubleCollection>10 3</DoubleCollection>
                                                  <DoubleCollection>20 6</DoubleCollection>
                                                  <DoubleCollection />
                                              </telerik:RadComboBox>



    Please suggest me something.

    Regards

    Yogendra kanojia
  5. Petar Mladenov
    Admin
    Petar Mladenov avatar
    2891 posts

    Posted 18 Sep 2013 Link to this post

    Hi Yogendra,

    Can you please confirm you are using our latest official Releases Q2 2013 or Q2 2013 SP ?
    If you are using this code with older assemblies we would kindly ask you to upgrade to our latest versions.

    Regards,
    Petar Mladenov
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
Back to Top