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

Edit details and commit data

2 Answers 78 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Peter
Top achievements
Rank 1
Peter asked on 17 Jun 2011, 07:42 AM
Hi

I use the RadTreeView with hierarchical data from a RadDomainDataSource. When I edit data in the details grid such as TxBeschrieb and click directly another node in the TreeView, the last edited textbox does not send back the edited data. If I click first another unbound textbox or button (without any function behind) and then another node, the data is sent back to the data source. Edit in the ComboBox does work well.

Thanks for help.


<telerik:RadTreeView Name="TV"
                     ScrollViewer.VerticalScrollBarVisibility="Visible"
                     IsLineEnabled="True"
                     IsLoadOnDemandEnabled="True"
                     IsEditable="False"
                     IsDragDropEnabled="False"
                     SelectedValuePath="kon_id"
                     IsEnabled="{Binding ElementName=RDDSupk, Path=IsBusy, Converter={StaticResource IsNotConverter1}}">
    <telerik:RadTreeView.ItemTemplate>
        <telerik:HierarchicalDataTemplate ItemsSource="{Binding Path=tKontoChildren, Mode=TwoWay}">
            <Grid>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="Auto" />
                    <ColumnDefinition Width="*" />
                </Grid.ColumnDefinitions>
                <TextBlock Text="{Binding kon_id}"   Grid.Column="0" Margin="4 2 2 2" VerticalAlignment="Center" FontWeight="Bold" />
                <TextBlock Text="{Binding kon_name}" Grid.Column="1" Margin="4 2 2 2" VerticalAlignment="Center"/>
            </Grid>
        </telerik:HierarchicalDataTemplate>
    </telerik:RadTreeView.ItemTemplate>
</telerik:RadTreeView>
 
 
    <Button Content="empty" Width="100" Margin="10,0,0,0"  />
    <TextBox Width="100" />
 
<Grid DataContext="{Binding ElementName=TV, Path=SelectedItem, Mode=TwoWay}" Name="GridDetails" >
 
    <TextBox Grid.Column="1" Grid.Row="2" Name="TxName"      Text="{Binding Path=kon_name,      Mode=TwoWay, NotifyOnValidationError=true, ValidatesOnExceptions=true}"  Margin="3" />
    <TextBox Grid.Column="1" Grid.Row="3" Name="TxBeschrieb" Text="{Binding Path=kon_beschrieb, Mode=TwoWay}"  Margin="3" Grid.ColumnSpan="2" />
 
    <telerik:RadComboBox Grid.Column="1" Grid.Row="4" telerik:StyleManager.Theme="Windows7" Margin="3"
                         ItemsSource="{Binding ElementName=RDDSunitsG, Path=DataView}"
                         DisplayMemberPath="uni_unit"
                         SelectedValuePath="uni_id"
                         SelectedValue="{Binding ElementName=TV, Path=SelectedItem.kon_uni_id, Mode=TwoWay, NotifyOnValidationError=True, ValidatesOnExceptions=True}" >
    </telerik:RadComboBox>
</Grid>

2 Answers, 1 is accepted

Sort by
0
Petar Mladenov
Telerik team
answered on 22 Jun 2011, 03:41 PM
Hello Peter,

This is common issue in the TextBox in Silverlight. Could you please try to use the RadMaskedTextBoxes instead of TextBoxes with MaskType set to "None" and UpdateValueEvent set to "LostFocus". Please let us know if this fits in your scenario and works for you. Thank you in advance for your cooperation.

Kind regards,
Petar Mladenov
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
0
Peter
Top achievements
Rank 1
answered on 22 Jun 2011, 04:02 PM
Hello Petar
Thanks a lot. That works great!
Tags
TreeView
Asked by
Peter
Top achievements
Rank 1
Answers by
Petar Mladenov
Telerik team
Peter
Top achievements
Rank 1
Share this question
or