How to set the CommandBarButton default size

2 posts, 0 answers
  1. Giovanni
    Giovanni avatar
    37 posts
    Member since:
    Feb 2011

    Posted 29 Oct 2012 Link to this post

    Hi,
    I tried to create a commandbar with only CommandBarButton elements, each one displayed as image only.
    How can I set by default the size to contains 32x32 images instead of 16x16?

    Thank you
  2. Anton
    Admin
    Anton avatar
    167 posts

    Posted 01 Nov 2012 Link to this post

    Hi Giovanni,

    If I understand correctly, you want to show image with size 32x32 in CommandBarButton element. If so, here is how you can do that: 
    1. Use image with size 32x32.
    2. Set the MinSize if you want to have space between image and borders of the button.

    this.commandBarButton3.Image = global::CommandBarButtonDefaultSize.Properties.Resources.Button_Next_icon32x32;
    this.commandBarButton3.MinSize = new System.Drawing.Size(40, 40);

    Hope this helps. Feel free to ask if you have any additional questions.

    Greetings,
    Anton
    the Telerik team
    Q3’11 of RadControls for WinForms is available for download (see what's new). Get it today.
  3. UI for WinForms is Visual Studio 2017 Ready
Back to Top