We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

LoadDynamicItems throws ArgumentException

Thread ID:





115965 Mar 6,2014 03:11 PM UTC Mar 10,2014 07:25 AM UTC WinRT 3
Tags: SfDataPager
Nicky Mogensen
Asked On March 6, 2014 03:11 PM UTC

Hi there

I have  a problem with the SfDataPager and/or the SfDataGrid.

I have a collection of objects of the type DataModel. This model has a propertycalled ClientSubmitDate, which is bound to the column. When the sfDataPager doesn't load data OnDemand it works fine. But when using OnDemandLoading and LoadDynamicItems the problem occours.

I doesnt matter what type of collection I'm using, both ObservableCollection and List throws the error.

Exception Message: 
An exception of type 'System.ArgumentException' occurred in System.Core.dll but was not handled in user code

Additional information: 'ClientSubmitDate' is not a member of type 'System.Object'

Method Calling LoadDynamicItems:
       private async void sfDataPager_OnDemandLoading(object sender, Syncfusion.UI.Xaml.Controls.DataPager.OnDemandLoadingEventArgs args)
            var data = (await Controller.DatabaseController.GetDataModelsForFormModel(Form, false, args.PageSize, args.StartIndex));
            sfDataPager.LoadDynamicItems(0, data);

If you need a sample model, my DataModel class could (for this example) be expressed like:
    public class DataModel
        public DateTime ClientSubmitDate { get; set; }

Please notice, that the bindings work without problems when NOT loading data on demand. The datatype that I submit as a argument in LoadDynamicData both fails with List<DataModel> and ObservableCollection<DataModel>.

Thanks in advance.

Pradeepa R V [Syncfusion]
Replied On March 7, 2014 12:59 PM UTC

Hi Nickey
We have analysed the reported issue with our sample;we are not able to reproduce the issue.Can you please revert us by modifying the sample I attached based on your application.This would be more helpful for us to serve you.

Please let us know if you have any concern.


Attachment: OnDemandPaging_9ce5d512.zip

Nicky Mogensen
Replied On March 7, 2014 03:01 PM UTC

Hi Pradeepa.

I've been trying to reproduce the issue, and I found it.

It seems like, there is a difference in how events get called, when using OnDemandLoading and not, so it was some code, that I thought already was active, there became active and, told the grid to sort on a propertyname instead of a columnname.

So it was some 6 months old code that suddenly made the error.

I'm really sorry for the inconvenience. 

Pradeepa R V [Syncfusion]
Replied On March 10, 2014 07:25 AM UTC

Hi Nickey

Thanks for your update.

We are glad  to hear that your issue has been  resolved.You can contact us at any time regarding any clarification.

As always we will be happy to assist you.




This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon