I've attached a sample project, inside the zip file is an overview.txt file that explains what we are trying to do in more detail.
How to reproduce:
If you start running the application and immediately click the search button – you see a postback and the results in the textboxes are displayed in the status textbox below:
But if you start the application and click around with the navigation controls (or select different rows on the grid) and then click on the search button – you get the following exception that appears to be coming from the grid control:
The string parameter 'key' cannot be null or empty. Parameter name: key
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.ArgumentException: The string parameter 'key' cannot be null or empty. Parameter name: key Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[ArgumentException: The string parameter 'key' cannot be null or empty.
Parameter name: key]
System.Web.UI.StateBag.get_Item(String key) +8820932
Infragistics.Web.UI.Framework.Data.DataRecord.GetValue(String fieldName) +87
Infragistics.Web.UI.GridControls.ControlDataRecord.GetValue(ControlDataField field) +240
Infragistics.Web.UI.GridControls.ControlDataItemCollection.GetValue(Int32 index) +207
Infragistics.Web.UI.GridControls.ControlDataItemCollection.GetValue(ControlDataItem item) +71
Infragistics.Web.UI.GridControls.ControlDataItem.get_Value() +47
Infragistics.Web.UI.GridControls.GridRecordItem.GetTextNode() +154
Infragistics.Web.UI.GridControls.ControlDataItem.Infragistics.Web.UI.GridControls.IXPathDataNavigableObject.get_Xml() +156
Infragistics.Web.UI.GridControls.XPathDataNavigable.GetNextSibling() +43
Infragistics.Web.UI.GridControls.XPathDataNavigator.MoveToNext() +87
Infragistics.Web.UI.GridControls.XPathDataNavigator.OutputToStream(XPathDataNavigator xpdn, XmlTextWriter stream, HtmlTextWriter htmlWriter) +329
Infragistics.Web.UI.GridControls.XPathDataNavigator.OutputToStream(XPathDataNavigator xpdn, XmlTextWriter stream, HtmlTextWriter htmlWriter) +318
Infragistics.Web.UI.GridControls.XPathDataNavigator.get_OuterXml() +199
Infragistics.Web.UI.GridControls.GridRenderer.RenderContents(HtmlTextWriter writer) +1251
Dear Pete (BSC),
Thank you for contacting Infragistics!
We have received your support request concerning your "string parameter 'key' cannot be null or empty" error, and this case has been assigned to me. Infragistics is dedicated to helping you solve this issue. Our team and I have done an initial review of your case and
I am looking into your sample and will get back to you by Friday with more information or questions for you.
If you have any questions or concerns with this, please let me know and I'll be glad to help.
Hi Pete (BSC),
I'm updating you to let you know that I'm able to reproduce the issue. I've found, so far, that this exception is being triggered when trying to access a BoundDataField "Field 9" which does not have a key assigned to it. I need some more time to research why this is occurring. I will have another update for you by Wednesday.