<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.harlamenkov.ru/index.php?action=history&amp;feed=atom&amp;title=EN%2Fdocumentation%2Fbasic_guide%2Fediting_spreadsheet_documents</id>
	<title>EN/documentation/basic guide/editing spreadsheet documents - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.harlamenkov.ru/index.php?action=history&amp;feed=atom&amp;title=EN%2Fdocumentation%2Fbasic_guide%2Fediting_spreadsheet_documents"/>
	<link rel="alternate" type="text/html" href="https://wiki.harlamenkov.ru/index.php?title=EN/documentation/basic_guide/editing_spreadsheet_documents&amp;action=history"/>
	<updated>2026-11-11T13:51:24Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.33.0</generator>
	<entry>
		<id>https://wiki.harlamenkov.ru/index.php?title=EN/documentation/basic_guide/editing_spreadsheet_documents&amp;diff=16889&amp;oldid=prev</id>
		<title>Sancho at 17:54, 6 September 2011</title>
		<link rel="alternate" type="text/html" href="https://wiki.harlamenkov.ru/index.php?title=EN/documentation/basic_guide/editing_spreadsheet_documents&amp;diff=16889&amp;oldid=prev"/>
		<updated>2011-09-06T17:54:52Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;Revision as of 17:54, 6 September 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l4&quot; &gt;Line 4:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 4:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|ShowPrevNext=block&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|ShowPrevNext=block&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|ShowPrevPage=block&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|ShowPrevPage=block&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|PrevPage=EN/documentation/basic_guide/&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;structure_of_spreadsheets&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|PrevPage=EN/documentation/basic_guide/&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;formatting_spreadsheet_documents&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|NextPage=EN/documentation/basic_guide/drawings_presentations&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|NextPage=EN/documentation/basic_guide/drawings_presentations&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|spread=block&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|spread=block&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Sancho</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.harlamenkov.ru/index.php?title=EN/documentation/basic_guide/editing_spreadsheet_documents&amp;diff=16856&amp;oldid=prev</id>
		<title>Sancho at 10:48, 6 September 2011</title>
		<link rel="alternate" type="text/html" href="https://wiki.harlamenkov.ru/index.php?title=EN/documentation/basic_guide/editing_spreadsheet_documents&amp;diff=16856&amp;oldid=prev"/>
		<updated>2011-09-06T10:48:21Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;Revision as of 10:48, 6 September 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l92&quot; &gt;Line 92:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 92:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/source&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;Documentation/&lt;/del&gt;Caution|Functions VAR, VARP, STDVERP return an incorrect value when applied to a properly defined range. See {{bug|22625}}.}}&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{Caution|Functions VAR, VARP, STDVERP return an incorrect value when applied to a properly defined range. See {{bug|22625}}.}}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Sancho</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.harlamenkov.ru/index.php?title=EN/documentation/basic_guide/editing_spreadsheet_documents&amp;diff=15960&amp;oldid=prev</id>
		<title>Sancho: Основной текст</title>
		<link rel="alternate" type="text/html" href="https://wiki.harlamenkov.ru/index.php?title=EN/documentation/basic_guide/editing_spreadsheet_documents&amp;diff=15960&amp;oldid=prev"/>
		<updated>2011-09-02T18:20:37Z</updated>

		<summary type="html">&lt;p&gt;Основной текст&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;lt;section begin=title /&amp;gt;&amp;lt;noinclude&amp;gt;{{DISPLAYTITLE:&amp;lt;/noinclude&amp;gt;Editing Spreadsheet Documents&amp;lt;noinclude&amp;gt;}}&amp;lt;/noinclude&amp;gt;&amp;lt;section end=title /&amp;gt;{{BreadCrumbL10n}}&lt;br /&gt;
&lt;br /&gt;
{{Documentation/BASICGuideTOC&lt;br /&gt;
|ShowPrevNext=block&lt;br /&gt;
|ShowPrevPage=block&lt;br /&gt;
|PrevPage=EN/documentation/basic_guide/structure_of_spreadsheets&lt;br /&gt;
|NextPage=EN/documentation/basic_guide/drawings_presentations&lt;br /&gt;
|spread=block&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
Whereas the previous section described the main structure of spreadsheet documents, this section describes the services that allow you to easily access individual cells or cell ranges.&lt;br /&gt;
&lt;br /&gt;
== Cell Ranges ==&lt;br /&gt;
In addition to an object for individual cells (&amp;lt;idl&amp;gt;com.sun.star.table.Cell&amp;lt;/idl&amp;gt; service), {{OOo}} also provides objects that represent cell ranges. Such &amp;lt;tt&amp;gt;CellRange&amp;lt;/tt&amp;gt; objects are created using the &amp;lt;tt&amp;gt;getCellRangeByName&amp;lt;/tt&amp;gt; call of the spreadsheet object:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;oobas&amp;quot;&amp;gt;&lt;br /&gt;
Dim Doc As Object&lt;br /&gt;
Dim Sheet As Object&lt;br /&gt;
Dim CellRange As Object&lt;br /&gt;
&lt;br /&gt;
Doc = ThisComponent&lt;br /&gt;
Sheet = Doc.Sheets.getByName(&amp;quot;Sheet 1&amp;quot;)&lt;br /&gt;
CellRange = Sheet.getCellRangeByName(&amp;quot;A1:C15&amp;quot;)&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A colon (:) is used to specify a cell range in a spreadsheet document. For example, A1:C15 represents all the cells in rows 1 to 15 in columns A, B, and C.&lt;br /&gt;
&lt;br /&gt;
If the position of the cell range is only known at runtime, use the following code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;oobas&amp;quot;&amp;gt;&lt;br /&gt;
Dim Doc As Object&lt;br /&gt;
Dim Sheet As Object&lt;br /&gt;
Dim CellRange As Object&lt;br /&gt;
&lt;br /&gt;
Doc = ThisComponent&lt;br /&gt;
Sheet = Doc.Sheets.getByName(&amp;quot;Sheet 1&amp;quot;)&lt;br /&gt;
CellRange = Sheet.getCellRangeByPosition(0, 0,  2, 14)&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The arguments of [http://api.openoffice.org/docs/common/ref/com/sun/star/sheet/XCellRangesAccess.html#getCellRangeByPosition &amp;lt;code&amp;gt;getCellRangeByPosition&amp;lt;/code&amp;gt;] are the position of the upper left cell of the range, followed by the position of the bottom right cell of the same range.&lt;br /&gt;
&lt;br /&gt;
The location of individual cells in a cell range can be determined using the &amp;lt;tt&amp;gt;getCellByPosition&amp;lt;/tt&amp;gt; method, where the coordinates of the top left cell in the cell range is (0, 0). The following example uses this method to create an object of cell C3.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;oobas&amp;quot;&amp;gt;&lt;br /&gt;
Dim Doc As Object&lt;br /&gt;
Dim Sheet As Object&lt;br /&gt;
Dim CellRange As Object&lt;br /&gt;
Dim Cell As Object&lt;br /&gt;
&lt;br /&gt;
Doc = ThisComponent&lt;br /&gt;
Sheet = Doc.Sheets.getByName(&amp;quot;Sheet 1&amp;quot;)&lt;br /&gt;
CellRange = Sheet.getCellRangeByName(&amp;quot;B2:D4&amp;quot;)&lt;br /&gt;
Cell = CellRange.GetCellByPosition(1, 1)&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Formatting Cell Ranges ===&lt;br /&gt;
&lt;br /&gt;
Just like individual cells, you can apply formatting to cell ranges using the &amp;lt;idl&amp;gt;com.sun.star.table.CellProperties&amp;lt;/idl&amp;gt; service. For more information and examples of this service, see [[Documentation/BASIC Guide/Formatting Spreadsheet Documents|Formatting Spreadsheet Documents]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Computing With Cell Ranges ===&lt;br /&gt;
&lt;br /&gt;
You can use the &amp;lt;tt&amp;gt;computeFunction&amp;lt;/tt&amp;gt; method to perform mathematical operations on cell ranges. The &amp;lt;tt&amp;gt;computeFunction&amp;lt;/tt&amp;gt; expects a constant as the parameter that describes the mathematical function that you want to use. The associated constants are defined in the &amp;lt;idl&amp;gt;com.sun.star.sheet.GeneralFunction&amp;lt;/idl&amp;gt; enumeration. The following values are available:&lt;br /&gt;
&lt;br /&gt;
;&amp;lt;tt&amp;gt;SUM&amp;lt;/tt&amp;gt;:sum of all numerical values&lt;br /&gt;
;&amp;lt;tt&amp;gt;COUNT&amp;lt;/tt&amp;gt;:total number of all values (including non-numerical values)&lt;br /&gt;
;&amp;lt;tt&amp;gt;COUNTNUMS&amp;lt;/tt&amp;gt;:total number of all numerical values&lt;br /&gt;
;&amp;lt;tt&amp;gt;AVERAGE&amp;lt;/tt&amp;gt;:average of all numerical values&lt;br /&gt;
;&amp;lt;tt&amp;gt;MAX&amp;lt;/tt&amp;gt;:largest numerical value&lt;br /&gt;
;&amp;lt;tt&amp;gt;MIN&amp;lt;/tt&amp;gt;:smallest numerical value&lt;br /&gt;
;&amp;lt;tt&amp;gt;PRODUCT&amp;lt;/tt&amp;gt;:product of all numerical values&lt;br /&gt;
;&amp;lt;tt&amp;gt;STDEV&amp;lt;/tt&amp;gt;:standard deviation&lt;br /&gt;
;&amp;lt;tt&amp;gt;VAR&amp;lt;/tt&amp;gt;:variance&lt;br /&gt;
;&amp;lt;tt&amp;gt;STDEVP&amp;lt;/tt&amp;gt;:standard deviation based on the total population&lt;br /&gt;
;&amp;lt;tt&amp;gt;VARP&amp;lt;/tt&amp;gt;:variance based on the total population&lt;br /&gt;
&lt;br /&gt;
The following example computes the average value of the &amp;lt;tt&amp;gt;A1:C3&amp;lt;/tt&amp;gt; range and prints the result in a message box:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;oobas&amp;quot;&amp;gt;&lt;br /&gt;
Dim Doc As Object&lt;br /&gt;
Dim Sheet As Object&lt;br /&gt;
Dim CellRange As Object&lt;br /&gt;
&lt;br /&gt;
Doc = ThisComponent&lt;br /&gt;
Sheet = Doc.Sheets.getByName(&amp;quot;Sheet 1&amp;quot;)&lt;br /&gt;
CellRange = Sheet.getCellRangeByName(&amp;quot;A1:C3&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
MsgBox CellRange.computeFunction(com.sun.star.sheet.GeneralFunction.AVERAGE)&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Documentation/Caution|Functions VAR, VARP, STDVERP return an incorrect value when applied to a properly defined range. See {{bug|22625}}.}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Deleting Cell Contents ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;clearContents&amp;lt;/tt&amp;gt; method simplifies the process of deleting cell contents and cell ranges in that it deletes one specific type of content from a cell range.&lt;br /&gt;
&lt;br /&gt;
The following example removes all the strings and the direct formatting information from the &amp;lt;tt&amp;gt;B2:C3&amp;lt;/tt&amp;gt; range.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;oobas&amp;quot;&amp;gt;&lt;br /&gt;
Dim Doc As Object&lt;br /&gt;
Dim Sheet As Object&lt;br /&gt;
Dim CellRange As Object&lt;br /&gt;
Dim Flags As Long&lt;br /&gt;
&lt;br /&gt;
Doc = ThisComponent&lt;br /&gt;
Sheet = Doc.Sheets(0)&lt;br /&gt;
CellRange = Sheet.getCellRangeByName(&amp;quot;B2:C3&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
Flags = com.sun.star.sheet.CellFlags.STRING + _&lt;br /&gt;
      com.sun.star.sheet.CellFlags.HARDATTR&lt;br /&gt;
&lt;br /&gt;
CellRange.clearContents(Flags)&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The flags specified in &amp;lt;tt&amp;gt;clearContents&amp;lt;/tt&amp;gt; come from the &amp;lt;idl&amp;gt;com.sun.star.sheet.CellFlags&amp;lt;/idl&amp;gt; constants list. This list provides the following elements:&lt;br /&gt;
&lt;br /&gt;
;&amp;lt;tt&amp;gt;VALUE&amp;lt;/tt&amp;gt;:numerical values that are not formatted as date or time&lt;br /&gt;
;&amp;lt;tt&amp;gt;DATETIME&amp;lt;/tt&amp;gt;:numerical values that are formatted as date or time&lt;br /&gt;
;&amp;lt;tt&amp;gt;STRING&amp;lt;/tt&amp;gt;:strings&lt;br /&gt;
;&amp;lt;tt&amp;gt;ANNOTATION&amp;lt;/tt&amp;gt;:comments that are linked to cells&lt;br /&gt;
;&amp;lt;tt&amp;gt;FORMULA&amp;lt;/tt&amp;gt;:formulas&lt;br /&gt;
;&amp;lt;tt&amp;gt;HARDATTR&amp;lt;/tt&amp;gt;:direct formatting of cells&lt;br /&gt;
;&amp;lt;tt&amp;gt;STYLES&amp;lt;/tt&amp;gt;:indirect formatting&lt;br /&gt;
;&amp;lt;tt&amp;gt;OBJECTS&amp;lt;/tt&amp;gt;:drawing objects that are connected to cells&lt;br /&gt;
;&amp;lt;tt&amp;gt;EDITATTR&amp;lt;/tt&amp;gt;:character formatting that only applies to parts of the cells&lt;br /&gt;
&lt;br /&gt;
You can also add the constants together to delete different information using a call from &amp;lt;tt&amp;gt;clearContents&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Searching and Replacing Cell Contents ==&lt;br /&gt;
&lt;br /&gt;
Spreadsheet documents, like text documents, provide a function for searching and replacing.&lt;br /&gt;
&lt;br /&gt;
The descriptor objects for searching and replacing in spreadsheet documents are not created directly through the document object, but rather through the &amp;lt;tt&amp;gt;Sheets&amp;lt;/tt&amp;gt; list. The following is an example of a search and replace process:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;oobas&amp;quot;&amp;gt;&lt;br /&gt;
Dim Doc As Object&lt;br /&gt;
Dim Sheet As Object&lt;br /&gt;
Dim ReplaceDescriptor As Object&lt;br /&gt;
Dim I As Integer&lt;br /&gt;
&lt;br /&gt;
Doc = ThisComponent&lt;br /&gt;
Sheet = Doc.Sheets(0)&lt;br /&gt;
&lt;br /&gt;
ReplaceDescriptor = Sheet.createReplaceDescriptor()&lt;br /&gt;
ReplaceDescriptor.SearchString = &amp;quot;is&amp;quot;&lt;br /&gt;
ReplaceDescriptor.ReplaceString = &amp;quot;was&amp;quot;&lt;br /&gt;
For I = 0 to Doc.Sheets.Count - 1&lt;br /&gt;
   Sheet = Doc.Sheets(I)&lt;br /&gt;
   Sheet.ReplaceAll(ReplaceDescriptor) &lt;br /&gt;
Next I&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This example uses the first page of the document to create a &amp;lt;tt&amp;gt;ReplaceDescriptor&amp;lt;/tt&amp;gt; and then applies this to all pages in a loop.&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
{{PDL1}}&lt;/div&gt;</summary>
		<author><name>Sancho</name></author>
		
	</entry>
</feed>