SelectedItem is not set

5 posts, 1 answers
  1. Richard Koslik
    Richard Koslik avatar
    71 posts
    Member since:
    Apr 2010

    Posted 10 May 2012 Link to this post

    Hello,

    I have bound the SelectedItem Property of a TabControl, but when I start my application the property has always the value NULL until I first click onto a Tabsheet. IsDefaultItemSelected = True has also no effect.

    Is use:
    - Silverlight 5
    - RadControlsVersion Q1 2012 SP1 (Runtime version v4.0.30319)
    - GalaSoft MVVM

    <telerik:RadTabControl IsDefaultItemSelected="True" TabStripPlacement="Left" BorderBrush="DarkGray" BorderThickness="1" TabOrientation="Vertical" Align="Right"  ScrollViewer.VerticalScrollBarVisibility="Auto"  VerticalAlignment="Top" Height="310" HorizontalAlignment="Left" Margin="5,581,0,0" Name="tcChild" Width="1639" 
                                     SelectedItem="{Binding tabItemChild, Mode=TwoWay}" SelectedIndex="{Binding iTabIndexChild, Mode=TwoWay}">

    What do I wrong??


    best regards
    Richard Koslik
  2. Answer
    Tina Stancheva
    Admin
    Tina Stancheva avatar
    3298 posts

    Posted 14 May 2012 Link to this post

    Hello Richard,

    I wasn't able to reproduce the issue. Can you please have a look at the attached sample and let me know if I'm missing something? Thank you in advance.

    Kind regards,
    Tina Stancheva
    the Telerik team

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

  3. DevCraft banner
  4. Richard Koslik
    Richard Koslik avatar
    71 posts
    Member since:
    Apr 2010

    Posted 15 May 2012 Link to this post

    Hello,

    thanks for your help. Your sample works fine, but my situation is another one.

    My tabsheets are created directly in the xaml. I changed your sample to my situation maybe you are able to find the problem, in the older Silverlight Controls version my solution worked fine.

    i will send you the .zip - file through a new support ticket.

    best regards, Richard Koslik
  5. Petar Mladenov
    Admin
    Petar Mladenov avatar
    2891 posts

    Posted 16 May 2012 Link to this post

    Hi Richard  ,

     We replied in your support thread. The problem's origin is the mix between ViewModels and static Radtabitems which is not supported.

    Greetings,
    Petar Mladenov
    the Telerik team

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

  6. Richard Koslik
    Richard Koslik avatar
    71 posts
    Member since:
    Apr 2010

    Posted 16 May 2012 Link to this post

    Hello,

    thanks for your support, I changed now my project, create the tabitems manually and it works.

     best regard,
    Richard Koslik
Back to Top
DevCraft banner