Solved

How do I update a RibbonComboBox in a WPF Application?

Posted on 2011-09-20
5
1,603 Views
Last Modified: 2012-06-27
Hi

I am creating a WPF Ribbon Application with Visual Basic .NET.

On the Ribbon, I have created a RibbonComboBox.  I have also created a collection (in code) of items and set that as my ItemSource for the RibbonComboBox at run-time.  This works fine and the items show up in the RibbonComboBox.

However, how do I get the RibbonComboBox to display the item I select from the list?  When I drop the box down and select something, it does not update to display the selected item - the field just stays empty.  I tried setting the Text property but this does not seem to work.  How do you get the RibbonComboBox to display the selected item?

Thanks
Vyyk
0
Comment
Question by:Vyyk_Drago
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 
LVL 6

Accepted Solution

by:
effes earned 500 total points
ID: 36571784
Hi Vyyk,

since there's been no answer to your question yet, I thought I'd share my "experience" with the Microsoft's WPF Ribbon. A word of warning though: I'm definitely no expert on WPF and I just played around a bit with the Ribbon earlier this year out of curiosity.
I remember that I adding a RibbonGallery and a RibbonGalleryCategory to the RibbonComboBox did the trick for me (see the sample at the end of the MSDN entry on the RibbonBox class here).
I don't know if that's the only or the best way to do it, but it's the only one I know of.

I hope that points you at least in the right direction.
Frank
0
 

Author Comment

by:Vyyk_Drago
ID: 36574374
Hi Frank,

Brilliant - it took me quite a while to figure out how to do this at run-time but that article helped a great deal nonetheless.  Many thanks!  My hero :)

All the best
Vykk \o/
0
 

Author Comment

by:Vyyk_Drago
ID: 36574709
I've requested that this question be closed as follows:

Accepted answer: 0 points for Vyyk_Drago's comment http:/Q_27318252.html#36574374

for the following reason:

Awesome - would not have managed to figure it out without reference to the article referred to by the poster.
0
 

Author Comment

by:Vyyk_Drago
ID: 36574710
Ack, I misclicked the accept button.  Please award the solution to Effe for posting a solution.

Thanks
Vyyk
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Well, all of us have seen the multiple EXCEL.EXE's in task manager that won't die even if you call the .close, .dispose methods. Try this method to kill any excels in memory. You can copy the kill function to create a check function and replace the …
Since .Net 2.0, Visual Basic has made it easy to create a splash screen and set it via the "Splash Screen" drop down in the Project Properties.  A splash screen set in this manner is automatically created, displayed and closed by the framework itsel…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

761 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question