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

Proper user of MigrantRange

Thread ID:





78400 Dec 11,2008 02:54 PM UTC Dec 12,2008 07:14 AM UTC WinForms 1
Tags: XlsIO
Administrator [Syncfusion]
Asked On December 11, 2008 02:54 PM UTC

I am looking for an example of the proper use of MigrantRange

I am rendering my own excel report and I need to be as efficient as possible. We have some customers that have over 120 000 rows with approx 14 columns.
Writing to excel like this
Excel[row, col].Text = value
Excel[row,col].CellStyle. =
is just not efficient.

I understand that MigrantRange works very efficiently. How do I use it
1 - get Excel.MigrantRange[row, col, lastRow,lastCol]
2 - pass my new IRange to my method
3 - use my new range created from MigrantRange

I have also heard some rumblings about MigrantRangeImpl. Which is better

Please advise ,

Geetha M [Syncfusion]
Replied On December 12, 2008 07:14 AM UTC

Hi Kelley,

Thank you for your interest in Syncfusion products.

In order to set column / row style for large number of rows, you can use SetDefaultRowStyle and SetDefaultColumnStyle. Here is the code snippet for this:

sheet.SetDefaultColumnStyle(1, colCount, bodyStyle);

This will reduce the time consumption to a great extent.

Use of Migrant Range will reduce the memory consumption, particularly when using large number of strings. Please go through our Performance sample in the below location (shipped with installation) which demonstrates both Style and MigrantRange:

My Documents\Syncfusion\EssentialStudio\{Version Number}\Windows\XlsIO.Windows\Samples\2.0\Featured Samples\Performance\CS\

Please let me know if you have any questions.



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

or the page will be automatically redirected to 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