1<?xml version="1.0" encoding="UTF-8"?>
2<helpdocument version="1.0">
3
4<!--
5***********************************************************************
6 *
7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
8 *
9 * Copyright 2000, 2010 Oracle and/or its affiliates.
10 *
11 * OpenOffice.org - a multi-platform office productivity suite
12 *
13 * This file is part of OpenOffice.org.
14 *
15 * OpenOffice.org is free software: you can redistribute it and/or modify
16 * it under the terms of the GNU Lesser General Public License version 3
17 * only, as published by the Free Software Foundation.
18 *
19 * OpenOffice.org is distributed in the hope that it will be useful,
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
22 * GNU Lesser General Public License version 3 for more details
23 * (a copy is included in the LICENSE file that accompanied this code).
24 *
25 * You should have received a copy of the GNU Lesser General Public License
26 * version 3 along with OpenOffice.org.  If not, see
27 * <http://www.openoffice.org/license.html>
28 * for a copy of the LGPLv3 License.
29 *
30 ************************************************************************
31 -->
32
33
34<meta>
35      <topic id="textswriterguidefields_userdataxml" indexer="include" status="PUBLISH">
36         <title xml-lang="en-US" id="tit">Querying User Data in Fields or Conditions</title>
37         <filename>/text/swriter/guide/fields_userdata.xhp</filename>
38      </topic>
39   </meta>
40   <body>
41<bookmark xml-lang="en-US" branch="index" id="bm_id3153398"><bookmark_value>fields; user data</bookmark_value>
42      <bookmark_value>user data; querying</bookmark_value>
43      <bookmark_value>conditions; user data fields</bookmark_value>
44      <bookmark_value>hiding;text, from specific users</bookmark_value>
45      <bookmark_value>text; hiding from specific users, with conditions</bookmark_value>
46      <bookmark_value>user variables in conditions/fields</bookmark_value>
47</bookmark>
48<paragraph xml-lang="en-US" id="hd_id3153398" role="heading" level="1" l10n="U"
49                 oldref="59"><variable id="fields_userdata"><link href="text/swriter/guide/fields_userdata.xhp" name="Querying User Data in Fields or Conditions">Querying User Data in Fields or Conditions</link>
50</variable></paragraph>
51      <paragraph xml-lang="en-US" id="par_id3154239" role="paragraph" l10n="U" oldref="60">You can access and compare some user data from conditions or fields. For example, you can compare user data with the following operators:</paragraph>
52      <table id="tbl_id3154255">
53         <tablerow>
54            <tablecell>
55               <paragraph xml-lang="en-US" id="par_id3155889" role="tablehead" l10n="U" oldref="94">Operator</paragraph>
56            </tablecell>
57            <tablecell>
58               <paragraph xml-lang="en-US" id="par_id3147110" role="tablehead" l10n="U" oldref="95">Meaning</paragraph>
59            </tablecell>
60         </tablerow>
61         <tablerow>
62            <tablecell>
63               <paragraph xml-lang="en-US" id="par_id3150508" role="tablecontent" l10n="U" oldref="96">== or EQ</paragraph>
64            </tablecell>
65            <tablecell>
66               <paragraph xml-lang="en-US" id="par_id3150531" role="tablecontent" l10n="U" oldref="97">equals</paragraph>
67            </tablecell>
68         </tablerow>
69         <tablerow>
70            <tablecell>
71               <paragraph xml-lang="en-US" id="par_id3150725" role="tablecontent" l10n="U" oldref="98">!= or NEQ</paragraph>
72            </tablecell>
73            <tablecell>
74               <paragraph xml-lang="en-US" id="par_id3150748" role="tablecontent" l10n="U" oldref="99">is not equal to</paragraph>
75            </tablecell>
76         </tablerow>
77      </table>
78
79      <paragraph xml-lang="en-US" id="par_id3153167" role="paragraph" l10n="U" oldref="101">If you want, you can use a condition to hide specific text in your document from a specific user.</paragraph>
80      <list type="ordered">
81         <listitem>
82            <paragraph xml-lang="en-US" id="par_id3153190" role="listitem" l10n="U" oldref="102">Select the text in the document that you want to hide.</paragraph>
83         </listitem>
84         <listitem>
85            <paragraph xml-lang="en-US" id="par_id3145273" role="listitem" l10n="U" oldref="103">Choose <emph>Insert - Section</emph>.</paragraph>
86         </listitem>
87         <listitem>
88            <paragraph xml-lang="en-US" id="par_id3145297" role="listitem" l10n="U" oldref="104">In the <item type="menuitem">Hide</item>
89               <emph/>area, select the <item type="menuitem">Hide</item> check box.</paragraph>
90         </listitem>
91         <listitem>
92            <paragraph xml-lang="en-US" id="par_id3155533" role="listitem" l10n="U" oldref="105">In the <emph>With Condition</emph> box, type <emph>user_lastname == "Doe"</emph>, where "Doe" is the last name of the user that you want to hide the text from. </paragraph>
93         </listitem>
94         <listitem>
95            <paragraph xml-lang="en-US" id="par_id3155573" role="listitem" l10n="U" oldref="107">Click <emph>Insert</emph> and then save the document.</paragraph>
96         </listitem>
97      </list>
98      <paragraph xml-lang="en-US" id="par_id3147760" role="note" l10n="U" oldref="108">The name of the hidden section can still be seen in the Navigator.</paragraph>
99      <paragraph xml-lang="en-US" id="par_id3147777" role="paragraph" l10n="U" oldref="61">The following table is a list of the user variables that you can access when defining a condition or a field:</paragraph>
100      <table id="tbl_id3147793">
101         <tablerow>
102            <tablecell>
103               <paragraph xml-lang="en-US" id="par_id3147819" role="tablehead" l10n="U" oldref="62">User variables</paragraph>
104            </tablecell>
105            <tablecell>
106               <paragraph xml-lang="en-US" id="par_id3147218" role="tablehead" l10n="U" oldref="63">Meaning</paragraph>
107            </tablecell>
108         </tablerow>
109         <tablerow>
110            <tablecell>
111               <paragraph xml-lang="en-US" id="par_id3147245" role="code" l10n="U" oldref="64">user_firstname</paragraph>
112            </tablecell>
113            <tablecell>
114               <paragraph xml-lang="en-US" id="par_id3147268" role="paragraph" l10n="U" oldref="65">First name</paragraph>
115            </tablecell>
116         </tablerow>
117         <tablerow>
118            <tablecell>
119               <paragraph xml-lang="en-US" id="par_id3145592" role="code" l10n="U" oldref="66">user_lastname</paragraph>
120            </tablecell>
121            <tablecell>
122               <paragraph xml-lang="en-US" id="par_id3145615" role="paragraph" l10n="U" oldref="67">Last name</paragraph>
123            </tablecell>
124         </tablerow>
125         <tablerow>
126            <tablecell>
127               <paragraph xml-lang="en-US" id="par_id3145642" role="code" l10n="U" oldref="68">user_initials</paragraph>
128            </tablecell>
129            <tablecell>
130               <paragraph xml-lang="en-US" id="par_id3145666" role="paragraph" l10n="U" oldref="69">Initials</paragraph>
131            </tablecell>
132         </tablerow>
133         <tablerow>
134            <tablecell>
135               <paragraph xml-lang="en-US" id="par_id3151200" role="code" l10n="U" oldref="70">user_company</paragraph>
136            </tablecell>
137            <tablecell>
138               <paragraph xml-lang="en-US" id="par_id3151223" role="paragraph" l10n="U" oldref="71">Company</paragraph>
139            </tablecell>
140         </tablerow>
141         <tablerow>
142            <tablecell>
143               <paragraph xml-lang="en-US" id="par_id3151250" role="code" l10n="U" oldref="72">user_street</paragraph>
144            </tablecell>
145            <tablecell>
146               <paragraph xml-lang="en-US" id="par_id3152912" role="paragraph" l10n="U" oldref="73">Street</paragraph>
147            </tablecell>
148         </tablerow>
149         <tablerow>
150            <tablecell>
151               <paragraph xml-lang="en-US" id="par_id3152940" role="code" l10n="U" oldref="74">user_country</paragraph>
152            </tablecell>
153            <tablecell>
154               <paragraph xml-lang="en-US" id="par_id3152963" role="paragraph" l10n="U" oldref="75">Country</paragraph>
155            </tablecell>
156         </tablerow>
157         <tablerow>
158            <tablecell>
159               <paragraph xml-lang="en-US" id="par_id3152990" role="code" l10n="U" oldref="76">user_zipcode</paragraph>
160            </tablecell>
161            <tablecell>
162               <paragraph xml-lang="en-US" id="par_id3145679" role="paragraph" l10n="U" oldref="77">Zip Code</paragraph>
163            </tablecell>
164         </tablerow>
165         <tablerow>
166            <tablecell>
167               <paragraph xml-lang="en-US" id="par_id3145706" role="code" l10n="U" oldref="78">user_city</paragraph>
168            </tablecell>
169            <tablecell>
170               <paragraph xml-lang="en-US" id="par_id3145729" role="paragraph" l10n="U" oldref="79">City</paragraph>
171            </tablecell>
172         </tablerow>
173         <tablerow>
174            <tablecell>
175               <paragraph xml-lang="en-US" id="par_id3145756" role="code" l10n="U" oldref="80">user_title</paragraph>
176            </tablecell>
177            <tablecell>
178               <paragraph xml-lang="en-US" id="par_id3145779" role="paragraph" l10n="U" oldref="81">Title</paragraph>
179            </tablecell>
180         </tablerow>
181         <tablerow>
182            <tablecell>
183               <paragraph xml-lang="en-US" id="par_id3156284" role="code" l10n="U" oldref="82">user_position</paragraph>
184            </tablecell>
185            <tablecell>
186               <paragraph xml-lang="en-US" id="par_id3156307" role="paragraph" l10n="U" oldref="83">Position</paragraph>
187            </tablecell>
188         </tablerow>
189         <tablerow>
190            <tablecell>
191               <paragraph xml-lang="en-US" id="par_id3156334" role="code" l10n="U" oldref="84">user_tel_work</paragraph>
192            </tablecell>
193            <tablecell>
194               <paragraph xml-lang="en-US" id="par_id3156357" role="paragraph" l10n="U" oldref="85">Business telephone number</paragraph>
195            </tablecell>
196         </tablerow>
197         <tablerow>
198            <tablecell>
199               <paragraph xml-lang="en-US" id="par_id3156384" role="code" l10n="U" oldref="86">user_tel_home</paragraph>
200            </tablecell>
201            <tablecell>
202               <paragraph xml-lang="en-US" id="par_id3149728" role="paragraph" l10n="U" oldref="87">Home telephone number</paragraph>
203            </tablecell>
204         </tablerow>
205         <tablerow>
206            <tablecell>
207               <paragraph xml-lang="en-US" id="par_id3149756" role="code" l10n="U" oldref="88">user_fax</paragraph>
208            </tablecell>
209            <tablecell>
210               <paragraph xml-lang="en-US" id="par_id3149778" role="paragraph" l10n="U" oldref="89">Fax number</paragraph>
211            </tablecell>
212         </tablerow>
213         <tablerow>
214            <tablecell>
215               <paragraph xml-lang="en-US" id="par_id3149806" role="code" l10n="U" oldref="90">user_email</paragraph>
216            </tablecell>
217            <tablecell>
218               <paragraph xml-lang="en-US" id="par_id3147294" role="paragraph" l10n="U" oldref="91">E-mail address</paragraph>
219            </tablecell>
220         </tablerow>
221         <tablerow>
222            <tablecell>
223               <paragraph xml-lang="en-US" id="par_id3147321" role="code" l10n="U" oldref="92">user_state</paragraph>
224            </tablecell>
225            <tablecell>
226               <paragraph xml-lang="en-US" id="par_id3147344" role="paragraph" l10n="U" oldref="93">State</paragraph>
227            </tablecell>
228         </tablerow>
229      </table>
230
231      <section id="relatedtopics">
232         <embed href="text/swriter/guide/fields.xhp#fields"/>
233         <embed href="text/swriter/guide/conditional_text.xhp#conditional_text"/>
234         <embed href="text/swriter/guide/hidden_text.xhp#hidden_text"/>
235         <paragraph xml-lang="en-US" id="par_id3147392" role="paragraph" l10n="C"><link href="text/swriter/02/14020000.xhp" name="List of operators">List of operators</link></paragraph>
236      </section>
237   </body>
238</helpdocument>