IEnumerable Sequence enumerated oddly

I have this code and the data source is being enumerated in a weird way.

The data is pulled from the network in chunks, and it seems that the Grid begins to enumerate (and pulls the first item) seven times. Then it begins another enumeration that pulls all the data then it stops.


  1. Why does it begin to enumerate and pull a single item, seven times?
  2. Why does it pull all the data (800+ items) when the Grid is set to paginate on demand?















}


@code {
private IEnumerable ConfigurationItems = Enumerable.Empty();
private int x = 0;
protected override async Task OnInitializedAsync()
{
ConfigurationItems = session.Configuration.GetConfigurationSeq();
}
}


I simplified the grid too, so it has a bare bones example (removed paging related stuff) and it still does this.


It is somewhat buggy using this forum editor, looks like stuff is lost or messed up if we edit a previous post that has code in.


3 Replies

SP Sarveswaran Palani Syncfusion Team September 5, 2022 06:10 PM UTC

Hi Hugh,


Thanks for contacting Syncfusion support


We have analyzed your query and still we are quite unclear about your exact requirement. So kindly share the following details to validate the reported query further at our end.

  1. How does the data request pass to the grid component?
  2. Kindly mention how you bind data source to grid either property or adaptor, if adaptor, kindly mention the type of adaptor you are using
  3. Share us the component runnable code example or entire code snippet
  4. Kindly share the image demos for easy understanding the query
  5. Please share more details relevant to your requirement


Above requested details will be helpful for us to validate the reported query at our end and provide solution as early as possible. 


Regards,

Sarveswaran PK



JU judykelvin September 5, 2022 08:37 PM UTC

I have this code and the data source is being enumerated in a weird way.

The data is pulled from the network in chunks, and it seems that the Grid begins to enumerate and pulls the first item seven times. 

Then it begins another enumeration that pulls all the data then it stops.

Green Acres




SP Sarveswaran Palani Syncfusion Team September 6, 2022 03:54 PM UTC

Hi Hugh,


From your update, we’re not able to get your requirement properly. So, we prepared sample based on your requirement using the IEnumerable data source. Kindly check and reproduce the reported issue in the provided sample.


It’ll be helpful for us to validate the reported query at our end and provide solution as early as possible. 


Regards,

Sarveswaran PK


Attachment: SfGridSample1_65d57169.zip

Loader.
Up arrow icon