With ArcGIS Online a familiar tool, complements to the
previous lab, there was a new lab created and finished to further accommodate
the user with the concept of Web GIS. The second lab consisted of an exercise
to introduce an extensive platform for creating Web GIS applications, ArcGIS
Flex Viewer. The main goal of the lab was to teach how to configure ArcGIS Flex
Application Builder to create web applications, and to also help find a GIS
service and use data for analytical services in creating that Web GIS
application. The structure of Flex XML (extensible markup language) was also
introduced for the creation and editing of configuration files within the
ArcGIS Flex Application Builder. By the end of the lab the user should be
familiar with, and able to customize ArcGIS for Flex Application Builder and
also be able to configure custom widgets using programming code.
Methods:
This lab began with creating a new application on ArcGIS
Viewer for Flex to help the user understand how to add basemaps, operational
layers, and how to configure pop-ups. When the application was created the
first step was to add the basemap, the basemaps can be selected from ArcGIS
Online, ArcGIS Server, or from the web. After selecting the streets basemap
from ArcGIS online the operational layer was added to the application. It was
obtained from one of the ArcGIS REST Servers which is an open web interface to host
GIS services published on ArcGIS Server, they can be accessed by using the
specific URL for each server type. We used services from Sample Server 1 (http://sampleserver1.arcgisonline.com/ArcGIS/rest/services)
to access this server it was entered in the search bar under the ArcGIS Server
tab in the Operational Layers window. The URL for Sample Server 1 was entered
in the search bar and the Census Block Points feature layer was selected for
addition to the application. When a feature layer is added to the application
the user can edit its configuration, this was done to the Census Block Points
layer so it would reveal a pop-up containing attribute data specific to the
census block when clicked on. The attributes of POP2000 (population),
HOUSEHOLDs, and HSE_UNITS (housing units) were chosen to be displayed within
the pop-up on the map.
After setting the pop-up configuration for the census block
data, ArcGIS Flex Application Builder allows the user to set the map extent so
when the map is opened in a browser it is set immediately to that resolution.
When the map extent is set the user can then move to the design section of the
application where a logo can be added and title, fonts, and colors can be
changed. With the final design touches finished up the map application can be
previewed and then saved for online use.
The second section of the lab was directed at exploring the
functionality of some of the widgets available for use on the application. The exploration began with the Draw and
Locator widgets from the predefined widgets menu bar within the ArcGIS Flex
Application Builder window. The widget known as Draw gives the opportunity to
draw various items on the map screen, such as lines, rectangles or various
polygons. A handy aspect of the Draw widget is that once a figure is drawn, the
widget can show the area or distance that figure covers, so a user could
measure the length of a road segment. The Locator widget is rather similar to
searching for addresses on Google Maps, as the user types in an address it responds
with a number of addresses that match the search along with a matching score
out of 100. This widget can give the user a very accurate estimate of where the
address is that they searched for.
The final part of the lab was to configure ArcGIS Flex
Application Builder XML files for the creation of a new widget. Flex is built
around MXML and ActionScript languages these languages give a computer
programmer the ability to develop rich internet applications with select
programs. They are mainly used in coalition to lay out the interface of
applications and create application behaviors on the internet. This section of
the lab demonstrated how to reference services through a Flex Application
configuration file and how to add custom widgets to an application.
The widget to be configured to work within ArcGIS Flex
Application Builder was called ChartM, this widget would give the user the
capability to draw a shape, using the basics of the draw tool, to select
multiple items on the map application and return a chart of the selected items
attributes. The widget need an XML file that would call upon its capabilities when
activated within the map application, that XML file can be written using
Notepad++. The XML code was provided by the Professor and re-typed into a new
file created by the user, this file was then referenced to within the universal
widget configuration file. Once written and implemented, the widget was
available for use within ArcGIS Flex Application Builder.
The final part of the lab was to add and configure a
provided widget to a new map application. This widget was capable of showing
thematic layers on a map. To add the widget into ArcGIS Flex Application
Builder it needed to be imported through the settings tab. When the settings
are shown the advanced settings were clicked and opened and then the ability to
manage custom widgets is available. Within the Manage Custom Widgets window the
user can add a new widget available for use within an application. Configuring
the new Thematic widget is rather simple, the settings need to be available to
edit, and once there the user can edit the classifications as they wish. This
was done for the demographic dataset found through a provided ArcGIS Server.
Results: (Links to
webmaps are unavailable for non-users until further notice)
The first part of the lab resulted in a map of Eau Claire
Block populations.
Figure 2-1. This screen shot shows the pop-up window with the dot map in Eau Claire, WI. |
This map application was a good way to introduce the
functionalities of ArcGIS Flex Application Builder. The steps in creating a map
application make the opportunities for the final product close to unlimited.
In part two of the lab it was required to build a custom web
mapping application. I built a web application showing the Atlantic Hurricanes
of 2000.
Figure 2-2. Screen shot of the hurricane tracks in the Atlantic Ocean in 2000. |
This data was obtained from http://sampleserver6.arcgisonline.com/ArcGIS/rest/services
it was relatively easy to work with, the only necessary steps were to edit the
pop-up windows and give it two widgets that were not previously used. I decide
to use the legend widget so a viewer can see what the items are that they are
looking at while viewing the map application.
For part three of the lab we added in the provided widget to
the Eau Claire Block Populations map.
Figure 2-3. Notice the bar chart on the left side showing data from the selection. |
The XML coding was difficult to grasp at
first, but our professor provided us with a preview of what the code should
look like, so was simpler to find the errors I made and correct them to have a
working widget. The final product gave a good bar graph of the selected block
groups, within the XML file the user can also configure the result of the
selection to return a pie chart.
The last part of the lab consisted of adding in the Thematic
widget to ArcGIS Flex Application Builder and then creating a demographic map
to display the population in western Wisconsin counties.
Figure 2-4. Screenshot of the Thematic widget in action, see the different classification schemes available in the dialog box. |
The widget configuration was a bit painstaking, however the
final product was very fascinating to interact with. Within the Thematic widget
settings it was necessary to change the <classificationlayerName>, <classificationlayerID>, <classificationFieldTypeDesc>,<classificationFieldType> all to the
proper values and descriptions for the widget to work properly. They started as
details for the states when we were assigned to use it for counties. Our
professor gave us the required changes to make and once done the widget worked
properly to our requests.
Sources:
ArcGIS Server Online
Provided and Processed by Dr. C. Wilson. 2012.
No comments:
Post a Comment