change view galleries text in toolbox

3 posts, 0 answers
  1. Kidder
    Kidder avatar
    13 posts
    Member since:
    Nov 2012

    Posted 12 Nov 2012 Link to this post

    Hi, 
    how can i change or remove "view galleries" bottom of the toolbox?
  2. Tina Stancheva
    Admin
    Tina Stancheva avatar
    3298 posts

    Posted 15 Nov 2012 Link to this post

    Hi Kidder,

    You can edit the ControlTemplate of the RadDiagramToolbox and remove both elements you've indicated. However, there is one other approach that you can use in case you don't want to edit the entire ControlTemplate of the toolbox. The button right next to the 'ViewGalleries' text has a predefined style which you can control through the RadDiagramToolbox.OpenCloseButtonStyle property. This is why you can create a custom style for that button that sets the Visibility of the button to Collapsed.

    Next, the 'ViewGalleries' text is displayed in a TextBlock element of the RadDiagramToolbox.ControlTemplate, which Text value is controlled through a LocalizaitonManager. This is why you can create a custom LocalizationManager class that defines an empty string for the Text value of the TextBlock in question.

    I attached a sample solution to demonstrate this approach. Please have a look at it and let me know if it helps.

    All the best,
    Tina Stancheva
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. DevCraft banner
  4. Kidder
    Kidder avatar
    13 posts
    Member since:
    Nov 2012

    Posted 15 Nov 2012 Link to this post

    Thank you very much.. 

    public override string GetStringOverride(string key)
            {
                if (key == "Toolbox_ViewGalleries")
                    return string.Empty;
                else
                    return base.GetStringOverride(key);
            }
Back to Top