Service description, description, copyright text

6447
7
06-01-2011 04:52 AM
KirkWebb1
New Contributor
Where do I edit these parameters - Service description, description, copyright text - I filled in all properties and metadata in my mxd but nothing shows up.  I also open properties and map service properties in the actual arcgis Service that I created and I try to type something into the description boxes but it won't let me enter anything.
thanks
0 Kudos
7 Replies
DonBarker
Occasional Contributor
Kirk,

I've been working on this problem for the last couple of weeks for San Mateo County (Calif) GIS.  I hope you and others will share notes.  Here are some of ours:

I wanted to understand how to author metadata so that it shows up in the ArcGIS Server REST directory and in map descriptions at ArcGIS Online.  And to find opportunities to author metadata once and use it in many places.

I used the ArcCatalog v10 metadata editor (ISO19115 NAP format) to author metadata for two map layers (feature classes) and one map document (.mxd).  I published the map service then examined the REST directory.  I found that:

For Layers in a Map Document:

- No text from any field in the metadata editor appears in the REST directory!!

- These fields are populated from the Layer Properties fields in the map document (mxd):
o  Description  (Description in mxd)
o  Copyright Text (Credits in mxd)

For Map Document (.mxd) that becomes a Map Server, these fields,
- Title
- Credits
can be edited in either the map doc or metadata editor, and they appear in both; overwriting each other.

Tags added in the Map Doc (.mxd) Properties page appear as "Tags for Searching" in the metadata editor.

This isn't much!  It appears that Esri isn't very serious about leveraging metadata for display in the REST directory.  Maybe metadata can be utilized more through the REST programming API -- I haven't researched that.  But seems to me that's not the main purpose of metadata, anyway.  It's primarily for humans to evaluate the usability of geospatial data (along with providing keywords for computer searches.)
 
I documented the metadate throughputs in an Excel table.  The table suggests five templates from which text could be pasted into different metadata input fields for reutilization.  And it shows where this text would show up in the REST directory and at ArcGIS Online.  Let me know if you want a copy of that reference table.
MilanSchmidt
New Contributor II
Hi,

I had similar problem to fill up ArcGIS Map Service Description. I have found these properties where to fill it up:

(ArcGIS server - Map Service Properities/General Description) Service Description:
(.mxd Data Frame Properties/General Name) Map Name:
(.mxd Data Frame Properties/General Description) Description:
(.mxd Data Frame Properties/General Credits) Copyright Text:

Document Info:
(.mxd Map Document Properties/Title) Title:
(.mxd Map Document Properties/Author) Author:
(.mxd Map Document Properties/Description) Comments:
(.mxd Map Document Properties/Summary) Subject:
(???) Category:
(.mxd Map Document Properties/Tags)  Keywords:
(.mxd Map Document Properties/Credits) Credits:

But I can not find where to fill up "Category:" properties.

Any idea?

Thank you
Milan Schmidt
TanuHoque
Esri Regular Contributor
you need to do this programatically by setting IDocumentInfo::Category property in ArcObjects.
0 Kudos
MilanSchmidt
New Contributor II
Dear Hoque,

thank you. I am sorry but it is a little user un-friendly for me.

Is there an easy way how to do it? Could you please give me a few steps where to start?
Is it set on level of .mxd and ArcMAP or ArcGIS server (.NET)?

Here is an example of filled up "Content" item:
http://server.arcgisonline.com/ArcGIS/rest/services/Demographics/USA_1990-2000_Population_Change/Map...

Is it really done by ArcObjects?

I found this link http://help.arcgis.com/en/sdk/10.0/arcobjects_net/ao_home.html Do I have to learn this to go through?

Thank you.
milan
0 Kudos
MilanSchmidt
New Contributor II
Sorry, mentioned link above

http://server.arcgisonline.com/ArcGIS/rest/services/Demographics/USA_1990-2000_Population_Change/Map...

is not a good example. I have made a mistake. There is not filled up item "Content" but "Comments".

thanks
milan
0 Kudos
roemhildtg
Occasional Contributor III

I was looking for a solution to this and eventually just wrote a script to do it. Just make a temp directory, and run this in the python console, and have fun.

#############################################
# Description: Updates the description of each layer in
# the current mxd.
#
# Useful if the metadata changes, and you want the metadata
# to be reflected in the mxd layer description
#############################################

import arcpy
from xml.etree.ElementTree import ElementTree
#set local variables
dir = arcpy.GetInstallInfo("desktop")["InstallDir"]
translator = dir + "Metadata/Translator/ESRI_ISO2ISO19139.xml"
mxd = arcpy.mapping.MapDocument("CURRENT")
df = arcpy.mapping.ListDataFrames(mxd)[0]
temp_path = "C:/temp"

for layer in arcpy.mapping.ListLayers(mxd, "*", df):
     if not layer.isGroupLayer:
          description_text = ""
          path = temp_path + '/' + layer.datasetName + '.xml'
          print path
          arcpy.ExportMetadata_conversion(layer.dataSource, translator, path)
          dom = xml.dom.minidom.parse(path)
          fields = ('abstract', 'purpose', 'credit')
          for field in fields:
               tags = dom.getElementsByTagName(field)
               print str( len(tags) ) + ' | ' + str( tags )
               if len(tags):
                    tag_string = tags[0].getElementsByTagName('gco:CharacterString')[0].childNodes[0].nodeValue
                    description_text = description_text + "\n\n" + field.capitalize() + ":\n" + tag_string
                    print description_text
                    layer.description = description_text
                    if field == 'credit':
                         layer.credit = tag_string
0 Kudos
roemhildtg
Occasional Contributor III

FYI, this script has been updated to be a little more robust.

esri-python-tools/UpdateMXDMetadata.py at master · roemhildtg/esri-python-tools · GitHub 

0 Kudos