Infragistics Error When Closing Form
When using the Infragistics grid control on a windows form, user sometimes gets the following error message: "ExceptionMsg=System.InvalidCastException: Unable to cast object of type 'Infragistics.Win.ToolTipFormEx' to type 'xxxx'."This is due to a bug in the Infragistics grid.
The fix is to dispose of the grid object in the _FormClosing() event of the form.
private void MyForm_FormClosing(object sender, FormClosingEventArgs e)
{
if (this.myGrid != null)
{
this.myGrid.Dispose();
}
}
Last modified by Mohit @ 4/8/2025 9:24:29 AM