xref: /trunk/main/helpcontent2/source/text/scalc/01/func_errortype.xhp (revision 195598447694ec8542914a9b51ae9942e8ebacd9)
1<?xml version="1.0" encoding="UTF-8"?>
2
3<!--***********************************************************
4 *
5 * Licensed to the Apache Software Foundation (ASF) under one
6 * or more contributor license agreements.  See the NOTICE file
7 * distributed with this work for additional information
8 * regarding copyright ownership.  The ASF licenses this file
9 * to you under the Apache License, Version 2.0 (the
10 * "License"); you may not use this file except in compliance
11 * with the License.  You may obtain a copy of the License at
12 *
13 *   http://www.apache.org/licenses/LICENSE-2.0
14 *
15 * Unless required by applicable law or agreed to in writing,
16 * software distributed under the License is distributed on an
17 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
18 * KIND, either express or implied.  See the License for the
19 * specific language governing permissions and limitations
20 * under the License.
21 *
22 ***********************************************************-->
23
24<helpdocument version="1.0">
25<meta>
26<topic id="textscalc01func_errortypexml" indexer="include" status="PUBLISH">
27<title id="tit" xml-lang="en-US">ERROR.TYPE</title>
28<filename>/text/scalc/01/func_errortype.xhp</filename>
29</topic>
30</meta>
31<body>
32<bookmark xml-lang="en-US" branch="index" id="bm_id3155541">
33<bookmark_value>ERROR.TYPE function</bookmark_value>
34<bookmark_value>error type</bookmark_value>
35</bookmark>
36<bookmark xml-lang="en-US" branch="hid/SC_HID_FUNC_ERROR_TYPE_ODF" id="bm_id3155542" localize="false"/>
37<paragraph role="heading" id="hd_id3155540" xml-lang="en-US" level="2" l10n="U"><variable id="errortype"><link href="text/scalc/01/func_errortype.xhp">ERROR.TYPE</link>
38</variable></paragraph>
39<paragraph role="paragraph" id="par_id3155543" xml-lang="en-US" l10n="U"><ahelp hid="HID_FUNC_ERROR_TYPE_ODF">Returns a number from 1 to 7 for the kind of error value.</ahelp> ERRORTYPE returns the error number of %PRODUCTNAME instead.</paragraph>
40<paragraph role="heading" id="hd_id3155544" xml-lang="en-US" level="3" l10n="U">Syntax</paragraph>
41<paragraph role="code" id="par_id3155545" xml-lang="en-US" l10n="U">ERROR.TYPE(Value)</paragraph>
42<paragraph role="paragraph" id="par_id3155546" xml-lang="en-US" l10n="U"><emph>Value</emph> is the value or cell reference to be checked.</paragraph>
43<paragraph role="heading" id="hd_id3155547" xml-lang="en-US" level="3" l10n="U">Return values</paragraph>
44<table id="tbl_id3155548">
45<tablerow>
46<tablecell>
47<paragraph role="tablehead" id="par_id3155549" xml-lang="en-US" l10n="U">Return value</paragraph>
48</tablecell>
49<tablecell>
50<paragraph role="tablehead" id="par_id3155550" xml-lang="en-US" l10n="U">Error type</paragraph>
51</tablecell>
52</tablerow>
53<tablerow>
54<tablecell>
55<paragraph role="tablecontent" id="par_id3155551" xml-lang="en-US" l10n="U">1</paragraph>
56</tablecell>
57<tablecell>
58<paragraph role="tablecontent" id="par_id3155552" xml-lang="en-US" l10n="U">#NULL!</paragraph>
59</tablecell>
60</tablerow>
61<tablerow>
62<tablecell>
63<paragraph role="tablecontent" id="par_id3155553" xml-lang="en-US" l10n="U">2</paragraph>
64</tablecell>
65<tablecell>
66<paragraph role="tablecontent" id="par_id3155554" xml-lang="en-US" l10n="U">#DIV/0!</paragraph>
67</tablecell>
68</tablerow>
69<tablerow>
70<tablecell>
71<paragraph role="tablecontent" id="par_id3155555" xml-lang="en-US" l10n="U">3</paragraph>
72</tablecell>
73<tablecell>
74<paragraph role="tablecontent" id="par_id3155556" xml-lang="en-US" l10n="U">#VALUE!</paragraph>
75</tablecell>
76</tablerow>
77<tablerow>
78<tablecell>
79<paragraph role="tablecontent" id="par_id3155557" xml-lang="en-US" l10n="U">4</paragraph>
80</tablecell>
81<tablecell>
82<paragraph role="tablecontent" id="par_id3155558" xml-lang="en-US" l10n="U">#REF!</paragraph>
83</tablecell>
84</tablerow>
85<tablerow>
86<tablecell>
87<paragraph role="tablecontent" id="par_id3155559" xml-lang="en-US" l10n="U">5</paragraph>
88</tablecell>
89<tablecell>
90<paragraph role="tablecontent" id="par_id3155560" xml-lang="en-US" l10n="U">#NAME?</paragraph>
91</tablecell>
92</tablerow>
93<tablerow>
94<tablecell>
95<paragraph role="tablecontent" id="par_id3155561" xml-lang="en-US" l10n="U">6</paragraph>
96</tablecell>
97<tablecell>
98<paragraph role="tablecontent" id="par_id3155562" xml-lang="en-US" l10n="U">#NUM!</paragraph>
99</tablecell>
100</tablerow>
101<tablerow>
102<tablecell>
103<paragraph role="tablecontent" id="par_id3155563" xml-lang="en-US" l10n="U">7</paragraph>
104</tablecell>
105<tablecell>
106<paragraph role="tablecontent" id="par_id3155564" xml-lang="en-US" l10n="U">#N/A</paragraph>
107</tablecell>
108</tablerow>
109</table>
110<paragraph role="paragraph" id="par_id3155565" xml-lang="en-US" l10n="U">If <emph>Value</emph> is not an error value, the function returns the #N/A error.</paragraph>
111<paragraph role="paragraph" id="par_id3155569" xml-lang="en-US" l10n="NEW">An error that %PRODUCTNAME shows as Err: and a number gets the number of the error value it becomes when the document is saved in Microsoft Excel format, for example 3 for Err:502.</paragraph>
112<paragraph role="heading" id="hd_id3155566" xml-lang="en-US" level="3" l10n="U">Examples</paragraph>
113<paragraph role="paragraph" id="par_id3155567" xml-lang="en-US" l10n="U"><item type="input">=ERROR.TYPE(1/0)</item> returns 2.</paragraph>
114<paragraph role="paragraph" id="par_id3155568" xml-lang="en-US" l10n="U"><item type="input">=ERROR.TYPE(NA())</item> returns 7.</paragraph>
115</body>
116</helpdocument>
117