You are on page 1of 5

HTML layouts for Identify tool

Now you can specify HTML layouts for each layer. Choose layer's properties in ArcMap, open "CarryMap Identify" tab. The default script contains Identify dialogue style and imaging. Default script:

Adding an image to Identify dialogue Type the following expression to the default script to add an image: <% var tag = '<img src="'; tag += CF.Values["Name"] + ".jpg"; tag += '">'; echo (tag); %> where: CF.Values["Name"] + ".jpg" - forms the name of the picture file attached. ["Name"] - field name taken from image description.

Therefore, when the current object has, for example, "Lynx" value, then the file name should be "Lynx.jpg". This file should be attached to the map file:

Please, note, that feature class should have a "Name" field. Adding an image and a text to Identify dialogue Text can be saved as .txt file. Type the following expression to the default script: <% var tag = '<img src="'; tag += CF.Values["Name"] + ".jpg"; tag += '">'; var name = CF.Values["Name"] + " description.txt"; echo (tag); include(name); %> where: var name = CF.Values["Name"] + " description.txt" - forms the name of the text file attached. Therefore, we have "Lynx" + "description.txt" = "Lynx description.txt". This file should be attached to the map file:

Please, note, that if feature class doesn't have "Name" field, or the description/image file is not attached to the map file, this feature will not work.

Preview CarryMap Identify dialogue in ArcMap You can view the script result in ArcMap by pressing "Preview" button, no need to convert the map to check it. The picture and the text for a particular object will be displayed when you have entered OBJECTID (FID field value for shapefile; OBJECTID value for geodatabase feature class)

Adding HTML to Identify dialogue Add the following expression to the default script: <% if(CF.Values["HTML"] == 1) { var name = CF.Values["ADDRESS"] + ".htm"; include(name); } else {%> where: if(CF.Values["HTML"] == 1) "HTML"=1 - field value. var name = CF.Values["ADDRESS"] + ".htm" - forms the name of the HTML file attached. Expression value: if HTML field value is 1, then HTML file with the name formed from "ADDRESS" field will be displayed. Otherwise, the field values from default script will be used. HTML file and associated images should be attached to the map file:

Preview HTML document in ArcMap HTML file for a particular object will be displayed when you have entered OBJECTID (FID field value for shapefile; OBJECTID value for geodatabase feature class)

You might also like