Working with tables...

3 posts, 0 answers
  1. Anthony
    Anthony avatar
    33 posts
    Member since:
    Nov 2010

    Posted 12 Apr 2012 Link to this post

    Hi, Telerik Team,

    Working with RichTextbox I have found that you can change table borders by selecting a table, clicking right mouse button and selecting "Table Borders..." on a context menu.However, I am curious whether it is possible to put this menu item from the context menu onto a panel(Home,Insert and etc.)...let's say under the Table tab???If possible can you give an example please.

    Best Regards,
    Anton.
  2. Martin Ivanov
    Admin
    Martin Ivanov avatar
    104 posts

    Posted 17 Apr 2012 Link to this post

    Hello Anthony,

    You need to edit the RadRichTextBoxRibbonUI and simply add 1 button at the desired place which in your case will be the RibbonTab with name Table. You need to add this RadRibbonButton:

    <telerik:RadRibbonButton CollapseToSmall="WhenGroupIsMedium" telerik:RadRichTextBoxRibbonUI.RichTextCommand="{Binding Path=ShowTablePropertiesDialogCommand}" Size="Medium" SmallImage="/Telerik.Windows.Controls.RichTextBoxUI;component/Images/MSOffice/16/TableProperties.png" Text="Table properties" />

    The only thing that you should have in mind is that the command can only be executed when the caret is inside a table. In case the current position of the caret is not inside a table (or the table is not selected), it will not be clear which table the settings should be applied to. Therefore, in these cases, the CanExecute method of the command returns false and the button will be disabled.

     Don't hesitate to contact us if you have other questions.

    Kind regards,
    Martin
    the Telerik team

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

  3. DevCraft banner
  4. Anthony
    Anthony avatar
    33 posts
    Member since:
    Nov 2010

    Posted 17 Apr 2012 Link to this post

    Thank you very much!I actually was lost in finding an appropriate command.Sometimes very difficult to find commands unfortunally.
Back to Top