“功能区组合框"并不总是选择您单击的项目. [英] Ribbon Combo Box not always selecting the item you click on.

查看:38
本文介绍了“功能区组合框"并不总是选择您单击的项目.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好

我正在使用WPF的功能区控件(版本4.0),偶尔遇到一个问题,当尝试从功能区组合框中选择一个项目时,该项目没有被选择并且该字段留为空白.以下是SelectionChanged之一的示例 我实现的事件处理程序,该事件处理程序附加到出现此问题的组合框之一.

I am using the Ribbon Control for WPF (Version 4.0), and am having an issue where occasionally, when attempting to select an item from a Ribbon Combo Box, the item is not selected and the field is left blank. The following is an example of one of the SelectionChanged event handlers that I have implemented which is attached to one of the Combo Boxes that are having this issue.

 

 private void VersionListGallery_SelectionChanged(object sender, RoutedPropertyChangedEventArgs<object> e)
 {
  if (this.VersionListGallery.SelectedItem == null)
  {
  return;
  }
  this.VersionId = (Identifier)this.VersionListGallery.SelectedItem;
 }

推荐答案

Hello Josh,

Hello Josh,

如何在Ribbon中定义ComboBox控件,我们必须将ComboBox放入RibbonGallary.请参考该主题.

How do you define your ComboBox controls in Ribbon, we must put the ComboBox into RibbonGallary. Please refer to this thread.

http://social.msdn.microsoft.com /Forums/en/wpf/thread/63a27ccc-2a39-4b01-acfc-621978e4633c

 

希望这会有所帮助.


这篇关于“功能区组合框"并不总是选择您单击的项目.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆