I am implementing a WPF PropertyGrid by using Infragistics XamPropertyGrid. However look there is an issue, the dropdown list for ColourType and CoreType display only Colours for select. CoreType should display Core1, Core2 and Core3, however Coretype now display Colours Value. Anything Wrong?
if I remove converter for Colour, then CoreType dropdown items display correct!!!! So I think this is a Bug of WPF PropertyGrid, hope I was wrong.
Please could anyone see all code for reproduce the issue following:
<Window x:Class="IGWpfApplication1.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="MainWindow" Height="522" Width="755" xmlns:ig="http://schemas.infragistics.com/xaml" Loaded="Window_Loaded">
<Grid>
<ig:XamPropertyGrid Margin="12,0,12,12" Name="xamPropertyGrid1" />
Grid>
Window>
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace IGWpfApplication1
{
///
/// Interaction logic for MainWindow.xaml
public partial class MainWindow : Window
public MainWindow()
InitializeComponent();
}
private void Window_Loaded(object sender, RoutedEventArgs e)
DataClass data1 = new DataClass();
data1.TrueOrFalse = true;
data1.CoreType = "Core2";
data1.ColourType = "Green";
this.xamPropertyGrid1.SelectedObject = data1;
dataClass:
using System.ComponentModel;
public class DataClass
private bool _trueOrFalse = false;
private String _coreType = "";
private String _colourType = "";
public bool TrueOrFalse
get{return _trueOrFalse;}
set{_trueOrFalse = value;}
[TypeConverter(typeof(CoreTypeConverter))]
public String CoreType
get{return _coreType;}
set{_coreType = value;}
[TypeConverter(typeof(ColourTypeConverter))]
public String ColourType
get{return _colourType;}
set{_colourType = value;}
public class CoreTypeConverter : StringConverter
public override bool GetStandardValuesSupported(ITypeDescriptorContext context)
{return true;}
public override bool GetStandardValuesExclusive(ITypeDescriptorContext context)
public override StandardValuesCollection GetStandardValues(ITypeDescriptorContext context)
List<string> list = DemodataClass.GetCoreList();
return new StandardValuesCollection(list);
public class ColourTypeConverter : StringConverter
List<string> list = DemodataClass.GetColourList();
public static class DemodataClass
// the following could return daynamic values from database.
private static List<string> CoreList = new List<string>() { "Core1", "Core2", "Core3" };
private static List<string> ColourList = new List<string>() { "Red", "Green", "Yellow" };
public static List<string> GetCoreList()
return CoreList;
public static List<string> GetColourList()
return ColourList;
This class works fine in Windows form Property grid.
Any one can help me out? Many thanks.
I have attached the project, please could anyone help debug and help to find the resolution?
Hello Bin,
Thank you for your post.
I have logged this behavior with our developers in our tracking system, with an issue ID of 205228. I have also created a support ticket on your behalf with number CAS-163235-W1T9Q2 in order to link the development issue to it so that you are automatically updated when a Service Release containing your fix is available for download.
Thanks Zhivko. Hope it can be resolved soon.
Kind Regards,
Bin
Hello Bin, We have shipped out a new service release where your issue is resolved. I'd be glad to find out if you had tested it out and if it had met your requirements.You can download the Service Releases by logging to our web site and going to Account\My Keys and Downloads.
https://www.infragistics.com/my-account/keys-and-downloads/