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

RadTreeListView Column Width CellEditTemplate

2 Answers 122 Views
TreeListView
This is a migrated thread and some comments may be shown as answers.
Patrice
Top achievements
Rank 1
Patrice asked on 04 Jun 2014, 04:23 PM
Hi,

I have a RadTreeListView in my application.
I have severals columns using CellEditTemplate.

When the size of the element in the CellEditTemplate gets bigger than the column's, the column is not resized.

For example : 
<telerik:GridViewDataColumn Header="{localization:Translate Key=PBODetailGrid_Perte, Default=PBODetailGrid_Perte}"
                                                    DataMemberBinding="{Binding Perte, Mode=TwoWay, Converter={StaticResource FormatAmountConverter},ConverterParameter='Perte'}"
                                                    TextAlignment="Right" 
                                                    IsFilterable="False"
                                                    UniqueName="lblPerteRTL"
                                                        MinWidth="60" >
                                <telerik:GridViewDataColumn.CellEditTemplate>
                                    <DataTemplate>
                                        <TextBox Text="{Binding Perte, 
                                                                        Mode=TwoWay,
                                                                    Converter={StaticResource FormatAmountNullConverter}}" HorizontalAlignment="Center"/>
                                    </DataTemplate>
                                </telerik:GridViewDataColumn.CellEditTemplate>

When the size of the TextBox is more important than the size of the column, the column is not resized.
Some columns in my RadTreeListView don't use DataTemplate, and their width resize normally.

Do you have an idea on how I can manage this issue ?

Thanks by advance :)

2 Answers, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 05 Jun 2014, 11:26 AM
Hello,

I tested how a column with CellEditTemplate defined is re-sized as the text typed into the editor (TextBox) becomes bigger and it worked fine at my side. 

You can check the attached demo solution as a reference. Would you please check it and let me know how can I observe the problematic behavior?

Regards,
Didie
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
0
Patrice
Top achievements
Rank 1
answered on 05 Jun 2014, 01:13 PM
Thanks for your answer.

With your sample, I manage to understand the problem.
One of the requirement of our project is to save the Settings of the Grid (column order, column visibility...), and this conflicted with the resizing process.

thanks again :)
Tags
TreeListView
Asked by
Patrice
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
Patrice
Top achievements
Rank 1
Share this question
or