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

Creating custom composite controls (like the BubbleBar example)

1 Answer 66 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Pete
Top achievements
Rank 1
Pete asked on 27 Oct 2011, 02:08 PM
Hi,

I've just been playing about with this BubbleBar component and I'm having trouble getting it to behave as described.

I've been working from the example in this thread:

http://www.telerik.com/community/forums/winforms/forms-and-dialogs/bubble-bar.aspx#1436417

I can download the code Nikolay provided as an attachement and run it and it works.

The problem comes when editing it.

Nikolay
says:

"After you add these files to your customer project, build it in order to get the BubbleBar component in the VS Toolbox. Then you should simply drag and drop BubbleBar to your form and fill it with RadButtonElement through the Edit Items menu item of the BubbleBar's ActionMenu."

However, even though I can build and run the sample code - I can't seem to get the component to appear in the toolbox. I have tried manaually adding it and it says it's already added, but it does not appear. I can edit the one that is on the form already, I just can't get it into the toolbox - so I can't easily add the control to another form.

I can wrap the BubbleBar in a standard WinForms control by copying the existing one on the demo form into a new control - the WinForms control appears in my tool box. This means that the VS toolbox is picking up the controls from my project - it's just not picking up the BubbleBar.

I want to be able to create custom controls based on the RadControls and I'm slightly worried something is set up wrong because I can't even get this demo control to work as expected. I don't want to spend time building up controls only to find that I have to hard code them because the designer doesn't support them properly.

I can load up the ExamplesCSVS2010.sln from the Q2 2011 Examples for WinForms - which includes the BubbleBar in the Integration examples - here I can get the BubbleBar running fine, but I can't get it into the Toolbox.

It's probably just something daft I'm doing wrong, I'm just getting the hang of these Rad bits...

Any pointers would be appreciated...

:)






1 Answer, 1 is accepted

Sort by
0
Ivan Petrov
Telerik team
answered on 31 Oct 2011, 10:24 AM
Hi Pete,

Thank you for writing.

Most probably, your BubbleBar is not visible in the VS toolbox, because you have not added the ToolboxItem(true) attribute to the bubble bar class that inherits from RadControl. Please, find attached a sample project where I have copied the bubble bar code from our demo application and have added a few lines of code which demonstrate how to add items to it. I have also added the aforementioned attribute and you should have a RadBubbleBar control visible in the VS toolbox.

I hope this will help you. If you have further questions I would be glad to help.

Kind regards,
Ivan Petrov
the Telerik team

Q2’11 SP1 of RadControls for WinForms is available for download (see what's new); also available is the Q3'11 Roadmap for Telerik Windows Forms controls.

Tags
General Discussions
Asked by
Pete
Top achievements
Rank 1
Answers by
Ivan Petrov
Telerik team
Share this question
or