This is a migrated thread and some comments may be shown as answers.

Error when RadComboBox posts back

3 Answers 111 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Brian Mains
Top achievements
Rank 1
Brian Mains asked on 26 Mar 2010, 04:25 PM
Hello,

I reload the items within a RadComboBox using the client-side API.  I'm not using the WS load on demand feature, but solely the JS api to add items to the combo.  When the items are refreshed and a postback happens, I'm getting this error below.  When it goes to load the combo client-state, an error occurs.  We are using the last 2009 Q3 version.

Thanks.

 

System.NullReferenceException: Object reference not set to an instance of an object.

at Telerik.Web.UI.ControlItem.LoadFromDictionary(IDictionary`2 dictionary)

at Telerik.Web.UI.ClientStateLogPlayer`1.Insert(ClientStateLogEntry entry, ControlItemCollection items, Int32 index)

at Telerik.Web.UI.ClientStateLogPlayer`1.Play(ClientStateLogEntry entry)

at Telerik.Web.UI.ClientStateLogPlayer`1.Play(IEnumerable`1 clientStateLogEntry)

at Telerik.Web.UI.RadComboBox.LoadClientState(RadComboBoxClientState clientState)

at Telerik.Web.UI.RadComboBox.LoadPostData(String postDataKey, NameValueCollection postCollection)

at Telerik.Web.UI.RadDataBoundControl.System.Web.UI.IPostBackDataHandler.LoadPostData(String postDataKey, NameValueCollection postCollection)

at System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad)

at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

3 Answers, 1 is accepted

Sort by
0
Simon
Telerik team
answered on 27 Mar 2010, 03:14 PM
Hello Brian Mains,

How are you adding the Items on the client side? Can you please paste here the relevant code?

Kind regards,
Simon
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Brian Mains
Top achievements
Rank 1
answered on 28 Mar 2010, 03:33 PM
Hey,

The only way that you can, by using the client-side API: http://www.telerik.com/help/aspnet-ajax/combo_clientsidebasics.html.  I've called trackChanges, and begin to clear the list, then add all of the relevant items.  Please let me know if this should be submitted as a support ticket.

FYI, I use trackChanges for the entire collection, not before and after each item.  Essentially it's doing:

track changes

clear old items

add 30 items to the list

commit changes

Thanks.
0
Simon
Telerik team
answered on 29 Mar 2010, 01:15 PM
Hi Brian Mains,

Thank you for this information.

Since this is a completely normal use-case there may be a bug in this functionality.

Please submit a support ticket and send us a page showing the issue, so that we inspect the bug right away.

Regards,
Simon
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
ComboBox
Asked by
Brian Mains
Top achievements
Rank 1
Answers by
Simon
Telerik team
Brian Mains
Top achievements
Rank 1
Share this question
or