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. Image for the cookie policy date
close icon

Referencing cells by their A1-style address

I'm using a GridControl. I need to programmatically reference several cells by their A1-style addresses. Is there any syntax for doing so? If not, does the Syncfusion library offer a function for converting between an A1-style address to a column number and row number?

-TC


2 Replies

JP Jeya Preetha M Syncfusion Team April 24, 2012 08:21 AM UTC

Hi Tc,

Thank you for your interest in Syncfusion Products.

To convert the row number and column number to A1 style address, Please make use of "GetAlphaLabel()" and "GetNumericLabel()" methods.


Console.Write(GridRangeInfo.GetAlphaLabel(3));
Console.Write(GridRangeInfo.GetNumericLabel(3));


Please let me know if you have any concerns.

Regards,
Jeya Preetha M



CB Chris Bishop replied to Administrator January 13, 2015 05:27 PM UTC

I'm using a GridControl. I need to programmatically reference several cells by their A1-style addresses. Is there any syntax for doing so? If not, does the Syncfusion library offer a function for converting between an A1-style address to a column number and row number?

-TC


To convert "A1":
Row 1 = model.Engine.RowIndex("A1")
Col 1 = model.Engine.ColIndex("A1")



Loader.
Live Chat Icon For mobile
Up arrow icon