View, edit, and zoom to MAP Attributes
1. Create a new Adobe Illustrator document.
2. Import world.mif from the Tutorial Data folder.
3. With all of the art selected on the world_area layer, click the MAP Attributes button on the MAPublisher toolbar or from the menu Window > MAPublisher > MAP Attributes.
4. Ensure the attribute table is set to All Features in the lower-left corner
5. To edit attribute values, double-click inside a cell, and type a new value.
All Features mode is only available when using Adobe Illustrator 2022 (version 26.x) or later. If you are using an older version, you will need to select the Selected features only mode.
All attribute values and some property attributes can be edited. MAPublisher creates some attributes which have the hash symbol (#) as a prefix. These attributes can be edited (but must be made visible first). However, #Area, #Perimeter, #VertexCount, and #Length are properties of the geometry and cannot be edited.
Keep in mind to enter values that correspond with a column's type (e.g. only enter numbers into a column of type Double or Integer). The edits are automatically maintained in the attribute table once entered.
6. The widths of the columns in the MAP Attributes panel may be changed by dragging the column separator left or right. Right-click and click Resize All To Fit Content.
7. Click the Population column heading to sort it in an ascending manner, then again to sort it in a descending manner.
All Features mode is only available when using Adobe Illustrator 2022 (version 26.x) or later
8. Zoom to a specific piece of art via the MAP Attributes panel. Select an attribute record and click the Zoom to Feature button. MAPublisher zooms to the area of the file where the artwork is located and displays it within visible handles.
Keep the document open for the next tutorial.
Add a new column to a MAP Attribute table
9. If necessary, open the MAP Attributes panel and select all objects on the world_area layer. The panel displays all of its attribute columns and values.
10. Click the Edit Schema button at the bottom of the MAP Attributes panel.
The Edit Schema dialog box displays the columns associated with the MAP Attributes table on the currently selected layer.
11. Click Add to add a new attribute column.
12. In the Name box, rename Attribute1 to Head of State.
Notice that spaces are not accepted for column names. MAPublisher inserts an underscore ( _ ) if space is typed into a column name. Also, notice that the Display Name box is populated with the same name. This can be changed to reflect a name with no spaces in it.
13. In the Display Name box, remove the spaces, so the name becomes Head of State.
14. In the Type drop-down list, choose String (this allows the column to contain alphanumeric values).
15. Set the size of 15 (this is the number of characters that can be displayed in each cell).
In certain instances, a default value for an attribute may be required. Setting a Default Value gives each record the same value. Do not enter a default value for this tutorial.
16. Click OK to close the dialog box.
The new column is created and can be given values in the MAP Attributes panel.
17. Leave the document open for the next tutorial.
Change an existing column's properties
18. If necessary, open the MAP Attributes panel and select all objects on the world_area layer.
19. Click the Edit Schema button and select Capital in the attribute column list.
20. In the Display Name box, rename it to Capital City. Also, change the size to 30.
The column type may be changed after it is created (e.g. convert a type double column to a type integer column). For this tutorial, leave the type as String. Also, any new polygons added to the world_area layer will have a default value of None.
21. Click OK.
The column is now renamed and its width is increased to accommodate longer names.
22. Leave the document open for the next tutorial.
Create a new column using expressions
23. If necessary, open the MAP Attributes panel and select all objects on the world_area layer.
24. Click the Edit Schema button.
25. Click Add to create a new attribute column called Population_Density and set the Type as Double.
26. Click the Derive value from expression checkbox and click the Expression Builder button next to the Edit Expression box.
Build expressions by making selections from the Objects list in combination with using the operators available at the top of the dialog box.
27. In the Expression Components section at the bottom of the dialog box, double-click the Population column in the Objects list, click the divide button "/", double-click SQKM. The final expression in the Edit Expression box is: Population/SQKM.
The expression is a valid statement means that the expression syntax is correct and can be performed.
28. Click OK to close the Attribute Expression Builder dialog box.
The expression box is populated with the expression that was just created.
29. Click OK again to close the Edit Schema dialog box. Scroll to the right to see the Population_Density column.
The Population_Density attribute column is updated with values calculated from the expression. Notice that these calculated values are grayed out. They can only be edited by modifying the attribute expression you just created or by changing the values in the Population or SQKM attributes.
30. Close the document without saving.
Want to follow along to this tutorial?
Please see our corresponding YouTube videos for the various MAPublisher tutorials covered in our online documentation!*
* Providing a general overview of the steps covered in this tutorial, our Working with MAP Attributes video tutorial will walk you through managing MAP Attributes in MAPublisher.
Comments
0 comments
Please sign in to leave a comment.