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

Invisible the Group Drop Down

2 Answers 35 Views
Panelbar (obsolete as of Q2 2010)
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Ching-Yen
Top achievements
Rank 1
Ching-Yen asked on 26 Apr 2008, 01:23 AM
hi,

When we select the style of the PanelBar to OutlookNavPane, it will show a "group drop down" where the user can "add/remove" button...

May I know how can we hide this button (I do not want the user to edit the layout)

Please advice.

2 Answers, 1 is accepted

Sort by
0
Kiril
Telerik team
answered on 28 Apr 2008, 04:41 PM
Hello Ching-Yen,

Thank you for writing.

You can hide the button in the OutlookNavPane view using the line below, assuming your RadPanelBar control is named radPanelBar1:

((

RadPanelBarOverFlow)radPanelBar1.RootElement.Children[0].Children[0].Children[1]).DropDownButton.Visibility = ElementVisibility.Collapsed;

I hope this helps. If you have any additional questions, please contact me again.


Best wishes,
Kiril
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Accepted
Kiril
Telerik team
answered on 29 Apr 2008, 08:30 AM
Hello Ching-Yen,

Just a quick follow up on the RadPanelBar code I sent you to hide the button.

In order to make sure the button does not appear in certain scenarios, please subscribe to the ControlAdded event of the RadPanelBar, and set the visibility of the button to Hidden (as opposed to Collapsed in the code I sent you before). You have to set the Visibility of the button to Hidded in the form constructor.

Please use the code below:

private

void Form1_Load(object sender, EventArgs e)
{
radPanelBar1.ControlAdded += new ControlEventHandler
(radPanelBar1_ControlAdded);

((RadPanelBarOverFlow)radPanelBar1.RootElement.Children[0].Children[0].Children[1]).DropDownButton.Visibility = Telerik.WinControls.ElementVisibility.Hidden;

}

void

radPanelBar1_ControlAdded(object sender, ControlEventArgs e)
{
((
RadPanelBarOverFlow)radPanelBar1.RootElement.Children[0].Children[0].Children[1]).DropDownButton.Visibility = Telerik.WinControls.ElementVisibility
.Hidden;
}


If you have additional questions, please contact me again.

Regards,
Kiril
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
Panelbar (obsolete as of Q2 2010)
Asked by
Ching-Yen
Top achievements
Rank 1
Answers by
Kiril
Telerik team
Share this question
or