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

RadDropDownButton with TableSizePicker

4 Answers 100 Views
Buttons
This is a migrated thread and some comments may be shown as answers.
Licenses
Top achievements
Rank 1
Licenses asked on 28 Jan 2011, 09:29 AM
Hello,

I'm using a RadDropDownButton that contains a TableSizePicker. I would like the dropdown to collapse automatically when the user clicks on the TableSizePicker. Setting the 'KeepOpen' property of the RadDropDownButton to false didn't work. Any ideas?

Here is a code snippet. The element name 'richTextEditor' refers to a RadRichTextBox
<telerik:RadDropDownButton x:Name="btnTable" DataContext="{Binding Commands, ElementName=richTextEditor}" Command="{Binding Path=InsertTableCommand}" KeepOpen="False" >
     <Image Source="..." Style="..." ToolTipService.ToolTip="..."/>
     <telerik:RadDropDownButton.DropDownContent>
         <telerik:RadButton ClickMode="Press">
             <telerik:TableSizePicker DataContext="{Binding Commands, ElementName=richTextEditor}" Command="{Binding Path=InsertTableCommand}" />
         </telerik:RadButton>
     </telerik:RadDropDownButton.DropDownContent>
</telerik:RadDropDownButton>

I also would like to apply localization on the TableSizePicker. This control currently contains text like 'Insert Table' and 'a x b Table' (where a and b are the number of columns and rows selected by the user in the TableSizePicker). I would like to replace 'Insert Table' and the word Table in 'a x b Table' by my own translations. Is this possible?

Thanks
Sodi

4 Answers, 1 is accepted

Sort by
0
Petar Mladenov
Telerik team
answered on 02 Feb 2011, 04:54 PM
Hi Sodi We,

By design, the TableSizePicker should be used with RadRibbonDropDownButton like so:
<telerik:RadRibbonDropDownButton  Width="120" Height="40" Background="Aqua"  >
    <telerik:RadRibbonDropDownButton.DropDownContent>
    <telerik:RadRibbonButton >
        <telerik:TableSizePicker  />
            </telerik:RadRibbonButton>
    </telerik:RadRibbonDropDownButton.DropDownContent>
</telerik:RadRibbonDropDownButton>
This way you will have the desired behavior of the button.
On the other hand the localization feature is  scheduled for Q1 2011.
Feel free to ask if you need further info.

Regards,
Petar Mladenov
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
Licenses
Top achievements
Rank 1
answered on 14 Feb 2011, 09:30 AM
Hello Petar,

This works. Thanks!

Regards,
Sodi
0
Licenses
Top achievements
Rank 1
answered on 30 Mar 2011, 10:48 AM
Hello Petar,

I installed version 2011.1.315.1040 of the Telerik controls. Is the localization feature for the TableSizePicker control included in this version? If yes,  how can I replace 'Insert Table' and the word Table in 'a x b Table' by my own translations? (a and b are the number of columns and rows selected by the user in the TableSizePicker)

Thanks
Sodi


0
Iva Toteva
Telerik team
answered on 01 Apr 2011, 04:02 PM
Hi Sodi We,
Localization is now supported on the TableSizePicker and all string that the rich text box uses.
You can refer to this forum thread for some information on localization in general and the default resource file.
There is also a small demo here (it is for WPF, but the resource files and the approach are pretty much the same).
The strings you would need to localize are:
  • Documents_TableSizePicker_InsertTable
  • Documents_TableSizePicker_TableSize
If you are using the table size picker in conjunction with a button that opens the InsertTableDialog
(like in the MS Word demo), you might also need to localize the strings in the InsertTableDialog:
  • Documents_InsertTableDialog_Header
  • Documents_InsertTableDialog_NumberMustBeBetween
  • Documents_InsertTableDialog_NumberOfColumns
  • Documents_InsertTableDialog_NumberOfRows
  • Documents_InsertTableDialog_TableSize
  • Cancel
  • Ok

Best wishes,
Iva
the Telerik team
Tags
Buttons
Asked by
Licenses
Top achievements
Rank 1
Answers by
Petar Mladenov
Telerik team
Licenses
Top achievements
Rank 1
Iva Toteva
Telerik team
Share this question
or