Skip to content

Commit c4616d7

Browse files
committed
new KB
1 parent ccba282 commit c4616d7

File tree

5 files changed

+15
-6
lines changed

5 files changed

+15
-6
lines changed
118 KB
Loading
25 KB
Loading
38.1 KB
Loading

knowledge-base/preventing-cell-formatting-extension-spreadprocessing.md

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ type: how-to
55
page_title: Avoiding Automatic Formatting Extension Below a Range in Excel with SpreadProcessing
66
meta_title: Avoiding Automatic Formatting Extension Below a Range in Excel with SpreadProcessing
77
slug: preventing-cell-formatting-extension-spreadprocessing
8-
tags: telerik-document-processing, spreadprocessing, excel-formatting, cell-formatting, worksheet
8+
tags: spread, processing, excel, formatting, cell, worksheet
99
res_type: kb
1010
ticketid: 1693269
1111
---
@@ -18,9 +18,16 @@ ticketid: 1693269
1818

1919
## Description
2020

21-
When exporting an Excel file using [SpreadProcessing](https://docs.telerik.com/devtools/document-processing/libraries/radspreadprocessing/overview) and applying formatting to a range of cells, entering data immediately below the formatted range may cause Excel to automatically extend the formatting. This occurs due to Excel's built-in "Extend data range formats and formulas" feature. The behavior is controlled by Excel itself and cannot be disabled programmatically from within the SpreadProcessing library.
21+
When exporting an Excel file using [SpreadProcessing](https://docs.telerik.com/devtools/document-processing/libraries/radspreadprocessing/overview) and applying formatting to a range of cells, entering data immediately below the formatted range may cause Excel to automatically extend the formatting:
2222

23-
Clearing the formatting of cells in a range below the formatted data helps mitigate this issue. However, this approach works only for pre-defined ranges and does not override Excel's internal settings permanently.
23+
>caption Extend Data Range Formats and Formulas
24+
![Microsoft Excel's built-in "Extend data range formats and formulas" feature ><](images/excel-extend-data-range-formatting.gif)
25+
26+
This occurs due to Excel's built-in *"Extend data range formats and formulas"* feature. The behavior is controlled by Excel itself and cannot be disabled programmatically from within the SpreadProcessing library:
27+
28+
![Microsoft Excel's built-in "Extend data range formats and formulas" setting ><](images/excel-extend-data-range-formatting.png)
29+
30+
Clearing the formatting of cells in a range below the formatted data helps mitigate behavior. However, this approach works only for pre-defined ranges and does not override Excel's internal settings permanently. This article demonstrates a sample approach how to rectify such a behavior.
2431

2532
## Solution
2633

@@ -75,8 +82,9 @@ static void SetDefaultFormattingCellRange(Worksheet worksheet, CellRange cellRan
7582

7683
This approach minimizes the chances of Excel automatically extending formatting when new data is entered below the formatted range.
7784

85+
![Eliminate the Microsoft Excel's built-in "Extend data range formats and formulas" setting ><](images/rectify-excel-extend-data-range-formatting.png)
86+
7887
## See Also
7988

80-
- [SpreadProcessing Overview](https://docs.telerik.com/devtools/document-processing/libraries/radspreadprocessing/overview)
81-
- [Working with Cell Formats](https://docs.telerik.com/devtools/document-processing/libraries/radspreadprocessing/features/formats)
82-
- [Working with Worksheets in SpreadProcessing](https://docs.telerik.com/devtools/document-processing/libraries/radspreadprocessing/features/worksheets)
89+
- [SpreadProcessing Overview]({%slug radspreadprocessing-overview%})
90+
- [Cell Styles]({%slug radspreadprocessing-features-styling-cell-styles%})

libraries/radspreadprocessing/features/styling/cell-styles.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,3 +216,4 @@ You can also remove a style from the __Styles__ collection. It is as easy as rem
216216
* [Document Themes]({%slug radspreadprocessing-features-styling-document-themes%})
217217
* [Whats is a Workbook?]({%slug radspreadprocessing-working-with-workbooks-what-is-workbook%})
218218
* [Retrieving Themable Cell Color in RadSpreadProcessing]({%slug retrieve-cell-color-radspreadprocessing%})
219+
* [Preventing Excel From Extending Cell Formatting Below Formatted Range Using SpreadProcessing]({%slug preventing-cell-formatting-extension-spreadprocessing%})

0 commit comments

Comments
 (0)