I am working on a clients application that is using CSLA Assembly Version 2.0.3.0. The error I am getting is
System.ArgumentOutOfRangeException was unhandled by user code
HResult=-2146233086
Message=Specified argument was out of the range of valid values.
Parameter name: rowIndex
Source=System.Windows.Forms
ParamName=rowIndex
StackTrace:
at System.Windows.Forms.DataGridView.InvalidateCell(Int32 columnIndex, Int32 rowIndex)
at System.Windows.Forms.DataGridView.DataGridViewDataConnection.ProcessListChanged(ListChangedEventArgs e)
at System.Windows.Forms.DataGridView.DataGridViewDataConnection.currencyManager_ListChanged(Object sender, ListChangedEventArgs e)
at System.Windows.Forms.CurrencyManager.OnListChanged(ListChangedEventArgs e)
at System.Windows.Forms.CurrencyManager.List_ListChanged(Object sender, ListChangedEventArgs e)
at System.Windows.Forms.BindingSource.OnListChanged(ListChangedEventArgs e)
at System.Windows.Forms.BindingSource.InnerList_ListChanged(Object sender, ListChangedEventArgs e)
at System.ComponentModel.BindingList`1.OnListChanged(ListChangedEventArgs e)
at System.ComponentModel.BindingList`1.Child_PropertyChanged(Object sender, PropertyChangedEventArgs e)
at Csla.Core.BindableBase.OnPropertyChanged(String propertyName) in C:\WOFCOCollection\MPS\Main\WinApps\GUI\Csla203\Core\BindableBase.cs:line 99
at Csla.Core.BusinessBase.PropertyHasChanged(String propertyName) in C:\WOFCOCollection\MPS\Main\WinApps\GUI\Csla203\Core\BusinessBase.cs:line 253
at Csla.Core.BusinessBase.PropertyHasChanged() in C:\WOFCOCollection\MPS\Main\WinApps\GUI\Csla203\Core\BusinessBase.cs:line 236
at JmFamily.Mps.Entities.MPSDYN03.Wmps02900d.set_ClientNbr(String value) in C:\WOFCOCollection\MPS\Main\WinApps\GUI\JMFamily.Entity\MPSDYN03\Wmps02900d.cs:line 665
at JMFamily.Mps.W_wmps_029.dw_detl_ue_select_ovl() in C:\WOFCOCollection\MPS\Main\WinApps\GUI\Mps\Mpsbe\W_wmps_029.cs:line 11261
at JMFamily.Mps.W_wmps_029.dw_detl_rowfocuschanged(Object sender, EventArgs e) in C:\WOFCOCollection\MPS\Main\WinApps\GUI\Mps\Mpsbe\W_wmps_029.cs:line 13515
at Metex.Core.DataUserControl.OnRowFocusChanged(EventArgs e) in C:\WOFCOCollection\MPS\Main\WinApps\GUI\Metex.Core\DataUserControl.cs:line 753
at Metex.Core.DataUserControl.RaiseRowFocusChangedEvent(Object sender, EventArgs e) in C:\WOFCOCollection\MPS\Main\WinApps\GUI\Metex.Core\DataUserControl.cs:line 828
at System.Windows.Forms.BindingSource.OnCurrentChanged(EventArgs e)
at System.Windows.Forms.BindingSource.CurrencyManager_CurrentChanged(Object sender, EventArgs e)
at System.Windows.Forms.CurrencyManager.OnCurrentChanged(EventArgs e)
InnerException:
nonSerializableHandlers.Invoke(this,
new PropertyChangedEventArgs(propertyName));
The code that causes this error follows
[EditorBrowsable(EditorBrowsableState.Advanced)]
protected virtual void OnPropertyChanged(string propertyName)
{
PropertyChangedEventHandler nonSerializableHandlers = _nonSerializableHandlers;if (nonSerializableHandlers != null )
nonSerializableHandlers.Invoke(this, new PropertyChangedEventArgs(propertyName));
PropertyChangedEventHandler serializableHandlers = _serializableHandlers;if (serializableHandlers != null)
serializableHandlers.Invoke(this, new PropertyChangedEventArgs(propertyName));
}
The propertyName parameter happens to be "ClientNbr" and when I look at the object reference by "this" it does contain a property named "ClientNbr". I cannot figure out why this error is occuring. The object uses a bindingSource.
Is this a known bug?. The PropertyHasChanged method is working correctly in countless other examples in the application but in this particular case there are three properties that are being changed on this object and they all have the same error.
Thanks