I can do this in the table, but would rather have ability in the labeling of the map.
RIck,
If you are after python specific code then you can use the str.format(), see examples here:
Python String Format Cookbook | mkaz.com
Rick,
Have a look at this article:
Make Numeric Labels More Readable
You could also use the FormatNumber function in vbscript:
http://www.esri.com/news/arcuser/1104/files/vbscript_label.pdf
Regards
Anthony
def makeMoney(n):
import locale
locale.setlocale(locale.LC_ALL, '')
S = locale.currency(float(n), grouping=True)
return S
Thank you Kevin,
Is there a way to remove the decimals from the currency, but have the thousands separator. I’m dealing with Sales Price of real estate and there usually no decimal place, ie. 100,000 for a home.
Richard
from the google:
http://stackoverflow.com/questions/23428660/python-locale-currency-to-0-decimals
Hopefully helpful?
A one liner (modified from code on Stack Overflow😞
<SPAN class="str">"{:,}"</SPAN><SPAN class="pun">.</SPAN><SPAN class="pln">format</SPAN><SPAN class="pun">(int(</SPAN><SPAN class="pln">value</SPAN><SPAN class="pun">))</SPAN>
Aangemelde leden kunnen berichten plaatsen, updates volgen en meer. Nieuw hier? Registreer een gratis account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.