i have a excel template and i formatted one of the cell as number .In code how to get the format of the cell
worksheet.Cells[0, 0] i need get the format assosiated with the cell
Thanks for your posting and using Aspose.Cells.
Please download and use the latest version:
for .NET v126.96.36.199
For your needs, you can access all the style/format related information of cell from Style object.
Style st = cell.GetStyle();
//Now access the format associated with cell from style object properties.
how to get format using Style st = cell.GetStyle();
like General,Date,Number,percentage that is i need to check my cell is Number formated or General formated or adte format
Please see these properties to find the number/date formats.
If the number/date format is built-in, you will find it in style.Number.
If the number/date format is custom, you will find in CultureCustom or Custom properties.
Please also see this document for your more help.
Setting Display Formats of Numbers and Dates