1cdf0e10cSrcweir<?xml version="1.0" encoding="UTF-8"?> 2cdf0e10cSrcweir 3ce44d6c1SAndrew Rist<!--*********************************************************** 4cdf0e10cSrcweir * 5ce44d6c1SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 6ce44d6c1SAndrew Rist * or more contributor license agreements. See the NOTICE file 7ce44d6c1SAndrew Rist * distributed with this work for additional information 8ce44d6c1SAndrew Rist * regarding copyright ownership. The ASF licenses this file 9ce44d6c1SAndrew Rist * to you under the Apache License, Version 2.0 (the 10ce44d6c1SAndrew Rist * "License"); you may not use this file except in compliance 11ce44d6c1SAndrew Rist * with the License. You may obtain a copy of the License at 12cdf0e10cSrcweir * 13ce44d6c1SAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 14cdf0e10cSrcweir * 15ce44d6c1SAndrew Rist * Unless required by applicable law or agreed to in writing, 16ce44d6c1SAndrew Rist * software distributed under the License is distributed on an 17ce44d6c1SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 18ce44d6c1SAndrew Rist * KIND, either express or implied. See the License for the 19ce44d6c1SAndrew Rist * specific language governing permissions and limitations 20ce44d6c1SAndrew Rist * under the License. 21cdf0e10cSrcweir * 22ce44d6c1SAndrew Rist ***********************************************************--> 23ce44d6c1SAndrew Rist 24cdf0e10cSrcweir<helpdocument version="1.0"> 25cdf0e10cSrcweir<meta> 26cdf0e10cSrcweir<topic id="textscalcguidevalidityxml" indexer="include" status="PUBLISH"> 27cdf0e10cSrcweir<title id="tit" xml-lang="en-US">Validity of Cell Contents</title> 28cdf0e10cSrcweir<filename>/text/scalc/guide/validity.xhp</filename> 29cdf0e10cSrcweir</topic> 30cdf0e10cSrcweir</meta> 31cdf0e10cSrcweir<body> 3282a98929Smseidel<bookmark xml-lang="en-US" branch="index" id="bm_id3156442"> 3382a98929Smseidel<bookmark_value>values; limiting on input</bookmark_value> 34cdf0e10cSrcweir<bookmark_value>limits; specifying value limits on input</bookmark_value> 35cdf0e10cSrcweir<bookmark_value>permitted cell contents</bookmark_value> 36cdf0e10cSrcweir<bookmark_value>data validity</bookmark_value> 37cdf0e10cSrcweir<bookmark_value>validity</bookmark_value> 38cdf0e10cSrcweir<bookmark_value>cells; validity</bookmark_value> 39cdf0e10cSrcweir<bookmark_value>error messages; defining for incorrect input</bookmark_value> 40cdf0e10cSrcweir<bookmark_value>actions in case of incorrect input</bookmark_value> 41cdf0e10cSrcweir<bookmark_value>Help tips; defining text for cell input</bookmark_value> 42cdf0e10cSrcweir<bookmark_value>comments;help text for cells</bookmark_value> 43cdf0e10cSrcweir<bookmark_value>cells; defining input help</bookmark_value> 44cdf0e10cSrcweir<bookmark_value>macros; running when incorrect input</bookmark_value> 45cdf0e10cSrcweir<bookmark_value>data; validity check</bookmark_value> 46cdf0e10cSrcweir</bookmark><comment>mw changed "limit...;"</comment> 47*df13e7c3Smseidel<paragraph role="heading" id="hd_id3156442" xml-lang="en-US" level="1" l10n="U"><variable id="validity"><link href="text/scalc/guide/validity.xhp" name="Validity of Cell Contents">Validity of Cell Contents</link> 48cdf0e10cSrcweir</variable></paragraph> 49*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3156283" xml-lang="en-US" l10n="U">For each cell, you can define entries to be valid. Invalid entries to a cell will be rejected.</paragraph> 50*df13e7c3Smseidel<paragraph role="warning" id="par_id3145252" xml-lang="en-US" l10n="U">The validity rule is activated when a new value is entered. If an invalid value has already been inserted into the cell, or if you insert a value in the cell either with drag-and-drop or by copying and pasting, the validity rule will not take effect.</paragraph> 51cdf0e10cSrcweir<paragraph role="note" id="par_id5174718" xml-lang="en-US" l10n="NEW">You can choose <emph>Tools - Detective</emph> at any time and choose the command <link href="text/scalc/01/06030800.xhp" name="Mark Invalid Data"><emph>Mark Invalid Data</emph></link> to display which cells contain invalid values.</paragraph> 52*df13e7c3Smseidel<paragraph role="heading" id="hd_id3155603" xml-lang="en-US" level="2" l10n="U">Using Cell Contents Validity</paragraph> 53cdf0e10cSrcweir<list type="ordered"> 54cdf0e10cSrcweir<listitem> 55*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3155959" xml-lang="en-US" l10n="U">Select the cells for which you want to define a new validity rule.</paragraph> 56cdf0e10cSrcweir</listitem> 57cdf0e10cSrcweir<listitem> 58*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3148837" xml-lang="en-US" l10n="U">Choose <item type="menuitem">Data - Validity</item>.</paragraph> 59cdf0e10cSrcweir</listitem> 60cdf0e10cSrcweir<listitem> 61*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3156020" xml-lang="en-US" l10n="U">On the <emph>Criteria</emph> tab page, enter the conditions for new values entered into cells.</paragraph> 62cdf0e10cSrcweir</listitem> 63cdf0e10cSrcweir<listitem> 64*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3159208" xml-lang="en-US" l10n="U">In the <emph>Allow</emph> field, select an option.</paragraph> 65cdf0e10cSrcweir</listitem> 66cdf0e10cSrcweir<listitem> 67*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3153011" xml-lang="en-US" l10n="U">If you select "Whole Numbers", values such as "12.5" are not allowed. Choosing "Date" allows date information both in the local date format as well as in the form of a <link href="text/sbasic/shared/03030101.xhp" name="serial date">serial date</link>. Similarly, the "Time" condition permits time values such as "12:00" or serial time numbers. "Text Length" stipulates that cells are allowed to contain text only.</paragraph> 68cdf0e10cSrcweir<paragraph role="paragraph" id="par_id9224829" xml-lang="en-US" l10n="NEW">Select "List" to enter a list of valid entries.</paragraph> 69cdf0e10cSrcweir</listitem> 70cdf0e10cSrcweir<listitem> 71*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3149317" xml-lang="en-US" l10n="U">Select the next condition under <emph>Data</emph>. According to what you choose, additional options will be selectable.</paragraph> 72cdf0e10cSrcweir</listitem> 73cdf0e10cSrcweir</list> 74*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3151389" xml-lang="en-US" l10n="U">After you have determined the conditions for cell validity, you can use the other two tab pages to create message boxes:</paragraph> 75cdf0e10cSrcweir<list type="unordered"> 76cdf0e10cSrcweir<listitem> 77*df13e7c3Smseidel<paragraph role="listitem" id="par_id3159261" xml-lang="en-US" l10n="U">On the <emph>Input Help</emph> tab page, enter the title and the text of the tip, which will then be displayed if the cell is selected.</paragraph> 78cdf0e10cSrcweir</listitem> 79cdf0e10cSrcweir<listitem> 80*df13e7c3Smseidel<paragraph role="listitem" id="par_id3156396" xml-lang="en-US" l10n="U">On the <emph>Error Alert</emph> tab page, select the action to be carried out in the event of an error.</paragraph> 81*df13e7c3Smseidel<paragraph role="listitem" id="par_id3147416" xml-lang="en-US" l10n="U">If you select "Stop" as the action, invalid entries are not accepted, and the previous cell contents are retained.</paragraph> 82*df13e7c3Smseidel<paragraph role="listitem" id="par_id3150033" xml-lang="en-US" l10n="U">Select "Warning" or "Information" to display a dialog in which the entry can either be canceled or accepted.</paragraph> 83*df13e7c3Smseidel<paragraph role="listitem" id="par_id3149947" xml-lang="en-US" l10n="U">If you select "Macro", then by using the <emph>Browse</emph> button you can specify a macro to be run in the event of an error.</paragraph> 84cdf0e10cSrcweir</listitem> 85cdf0e10cSrcweir</list> 86*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3149011" xml-lang="en-US" l10n="U">To display the error message, select <emph>Show error message when invalid values are entered</emph>.</paragraph> 87cdf0e10cSrcweir<embed href="text/scalc/01/12120300.xhp#examplemakro"/> 88*df13e7c3Smseidel<paragraph role="note" id="par_id3148586" xml-lang="en-US" l10n="U">After changing the action for a cell on the <emph>Error Alert</emph> tab page and closing the dialog with OK, you must first select another cell before the change takes effect.</paragraph> 89cdf0e10cSrcweir<section id="relatedtopics"> 90*df13e7c3Smseidel<paragraph role="paragraph" id="par_id3154805" xml-lang="en-US" l10n="U"><link href="text/scalc/01/12120000.xhp" name="Data - Validity">Data - Validity</link></paragraph> 91cdf0e10cSrcweir</section> 92cdf0e10cSrcweir</body> 93cdf0e10cSrcweir</helpdocument> 94