C#.NET Winforms PropertyGrid reports "Properties Window", "Index was outside the bounds of the array".

You may find when using the PropertyGrid in a C#.NET Winforms application that the PropertyGrid displays an alert with the title "Properties Window" and the message "Index was outside the bounds of the array" when you are editing a collection.



This is a somewhat misleading error as this can occur if you are modifying a Collection<T> where the object



/// <summary>
/// Represents an ODBC data source property.
/// </summary>
[Serializable]
[XmlRoot("Property")]
public abstract class OdbcDataSourceProperty : GlobalSerializableBase, IComparable<OdbcDataSourceProperty>
{


Remove the abstract modifier and the problem will go away.



Comments

Popular posts from this blog

SOLVED: Exchange Online Management PowerShell Connect-ExchangeOnline bug "A window handle must be configured. See https://aka.ms/msal-net-wam#parent-window-handles"

System error 86 has occurred. The specified network password is not correct.

The security identifier of the "NT SERVICE\WdiServiceHost" account is "S-1-5-80-3139157870-2983391045-3678747466-658725712-1809340420"