<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Label Expression in Mapping Questions</title>
    <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132069#M1528</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a simple label expression that I use for utility lines that give me size and material in a mapbook.&lt;/P&gt;&lt;P&gt;[diameter] +&amp;nbsp; "in "&amp;nbsp; +&amp;nbsp; [materialType]&lt;/P&gt;&lt;P&gt;I have values that are &amp;lt;Null&amp;gt;. Thru the label expression is there script that I can add to replace the &amp;lt;Null&amp;gt; with a question mark etc. I know I can just change the field, but would be nice to have the expression do it&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 21 Aug 2015 13:53:15 GMT</pubDate>
    <dc:creator>MikeFroese</dc:creator>
    <dc:date>2015-08-21T13:53:15Z</dc:date>
    <item>
      <title>Label Expression</title>
      <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132069#M1528</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a simple label expression that I use for utility lines that give me size and material in a mapbook.&lt;/P&gt;&lt;P&gt;[diameter] +&amp;nbsp; "in "&amp;nbsp; +&amp;nbsp; [materialType]&lt;/P&gt;&lt;P&gt;I have values that are &amp;lt;Null&amp;gt;. Thru the label expression is there script that I can add to replace the &amp;lt;Null&amp;gt; with a question mark etc. I know I can just change the field, but would be nice to have the expression do it&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 13:53:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132069#M1528</guid>
      <dc:creator>MikeFroese</dc:creator>
      <dc:date>2015-08-21T13:53:15Z</dc:date>
    </item>
    <item>
      <title>Re: Label Expression</title>
      <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132070#M1529</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/123343_pastedImage_1.png" style="max-width: 1200px; max-height: 900px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 14:52:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132070#M1529</guid>
      <dc:creator>WesMiller</dc:creator>
      <dc:date>2015-08-21T14:52:57Z</dc:date>
    </item>
    <item>
      <title>Re: Label Expression</title>
      <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132071#M1530</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In Python? See Picture below&amp;nbsp;&amp;nbsp; vbscript you would test for isNull&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Null.png" class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/123353_Null.png" style="height: auto;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 15:00:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132071#M1530</guid>
      <dc:creator>TedKowal</dc:creator>
      <dc:date>2015-08-21T15:00:58Z</dc:date>
    </item>
    <item>
      <title>Re: Label Expression</title>
      <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132072#M1531</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for quick response. &lt;/P&gt;&lt;P&gt;My label expression box only shows Jscript and VBScript parsers. I have ArcMap 10 does that matter.&lt;/P&gt;&lt;P&gt;Sorry I am a GIS/CAD guy and don't know much about scripts.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 15:32:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132072#M1531</guid>
      <dc:creator>MikeFroese</dc:creator>
      <dc:date>2015-08-21T15:32:37Z</dc:date>
    </item>
    <item>
      <title>Re: Label Expression</title>
      <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132073#M1532</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for quick response. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sorry I am a GIS/CAD guy and don't know much about scripts.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is the fieldvalue a default name or do I put my values in. Plus what is FLG=&lt;/P&gt;&lt;P&gt;Mine comes up with either diameter= or materialtype=&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 15:43:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132073#M1532</guid>
      <dc:creator>MikeFroese</dc:creator>
      <dc:date>2015-08-21T15:43:02Z</dc:date>
    </item>
    <item>
      <title>Re: Label Expression</title>
      <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132074#M1533</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.esri.com/people/froze123"&gt;Mike Froese&lt;/A&gt;​ the syntax is different maybe someone else will chime in with the proper syntax&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 15:44:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132074#M1533</guid>
      <dc:creator>WesMiller</dc:creator>
      <dc:date>2015-08-21T15:44:07Z</dc:date>
    </item>
    <item>
      <title>Re: Label Expression</title>
      <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132075#M1534</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Wes,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had something similar, but ended-up using falsy logic on the null string check:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;def FindLabel ( [NominalDiameter], [Material] ):
&amp;nbsp;&amp;nbsp;&amp;nbsp; ins, material, nd, q = ' in ', str([Material]), str([NominalDiameter]), '?'
&amp;nbsp;&amp;nbsp;&amp;nbsp; if not [Material]:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; label = ''.join([nd, ins, q])
&amp;nbsp;&amp;nbsp;&amp;nbsp; else:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; label = ''.join([nd, ins, material])
&amp;nbsp;&amp;nbsp;&amp;nbsp; return label&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 07:24:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132075#M1534</guid>
      <dc:creator>ChrisSmith7</dc:creator>
      <dc:date>2021-12-11T07:24:34Z</dc:date>
    </item>
    <item>
      <title>Re: Label Expression</title>
      <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132076#M1535</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;One trick to format the field name correctly is to place your cursor where you want to insert the field then double click on the name of the field list in the box above.&amp;nbsp; The field name should be inserted properly formatted for the scripting language you are using.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this make sense!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 16:08:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132076#M1535</guid>
      <dc:creator>TedKowal</dc:creator>
      <dc:date>2015-08-21T16:08:55Z</dc:date>
    </item>
    <item>
      <title>Re: Label Expression</title>
      <link>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132077#M1536</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;My field, called "NULLS", has some nulls and some values. Use IsNull() to test in VBScript:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;Function FindLabel ( [NULLS] )
if IsNull([NULLS]) then
&amp;nbsp; label = "?"
else
&amp;nbsp; label = [NULLS]
end if
FindLabel = label
End Function&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 07:24:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/mapping-questions/label-expression/m-p/132077#M1536</guid>
      <dc:creator>DarrenWiens2</dc:creator>
      <dc:date>2021-12-11T07:24:37Z</dc:date>
    </item>
  </channel>
</rss>

