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 : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to get excel merge count.

Thread ID:

Created:

Updated:

Platform:

Replies:

19608 Sep 30,2004 07:35 AM UTC Oct 2,2004 02:02 AM UTC WinForms 3
loading
Tags: XlsIO
Vu Dang Quang
Asked On September 30, 2004 07:35 AM UTC

In my excel sheet. I''ve merge A1:A9. When I using ExcelRW read Range[A1]. How do I knrow colspan. Anybody know can tell me.

Greg
Replied On September 30, 2004 12:23 PM UTC

Personally, I scan through the merged section before accessing individual cells. You might put this info in a collection to test against when you read each cell. Maybe SyncFusion has a better recommendation. foreach (IRange ecell in wk.MergedCells) { top = ecell.Row; left = ecell.Column; bottom = top + ecell.Rows.Length - 1; right = left + ecell.Columns.Length - 1; }

Administrator [Syncfusion]
Replied On September 30, 2004 01:25 PM UTC

Hi, Thanks for your input Greg. We have added a new property IRange.MergeArea which will return a Range that encapsulates the Merged cells. Unfortunately we do not have an updated evaluation version available right now, so please open a Direc-Trac incident in this regard and I will try to provide you with an updated evaluation version as soon as possible. Thanks. Best regards, Stephen. >Personally, I scan through the merged section before accessing individual cells. You might put this info in a collection to test against when you read each cell. Maybe SyncFusion has a better recommendation. > > foreach (IRange ecell in wk.MergedCells) > { > > top = ecell.Row; > left = ecell.Column; > bottom = top + ecell.Rows.Length - 1; > right = left + ecell.Columns.Length - 1; >}

Vu Dang Quang
Replied On October 2, 2004 02:02 AM UTC

Thanks for Greg. I''ve try using it code and it works good. vdquang >Personally, I scan through the merged section before accessing individual cells. You might put this info in a collection to test against when you read each cell. Maybe SyncFusion has a better recommendation. > > foreach (IRange ecell in wk.MergedCells) > { > > top = ecell.Row; > left = ecell.Column; > bottom = top + ecell.Rows.Length - 1; > right = left + ecell.Columns.Length - 1; >}

CONFIRMATION

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.

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

;