Select to view content in your preferred language

Adding Shape file data in ArcGIS viewer for flex 2.2

2721
1
01-12-2011 06:13 AM
ShingayiJoyah
New Contributor
So on this web application I would like to present physical addresses for all the parcels and zones or zip codes. all my data is in shape file formate and in Geographical coordinate system. so how do I go about it????

I managed to add four layers for my study area in Blantyre (Malawi, Africa), in my Config.xml, which are showing in my LayerList Widget but I can�??t see them in my map? Can you look at my Config file and tell me where I�??m going wrong????

I think my main problem is how to use the URL???? do I need to upload my data on ArcGIServer or its also possible to link my data from my PC...???

Here is my Config file so far...

<?xml version="1.0" ?>
<!--
////////////////////////////////////////////////////////////////////////////////
//
// Copyright (c) 2010 ESRI
//
// All rights reserved under the copyright laws of the United States.
// You may freely redistribute and use this software, with or
// without modification, provided you include the original copyright
// and use restrictions.  See use restrictions in the file:
// <install location>/License.txt
//
// Read more about ArcGIS Viewer for Flex 2.2 - http://links.esri.com/flexviewer
//
////////////////////////////////////////////////////////////////////////////////
-->
<configuration>
    <title>LACOSUS</title>
    <subtitle>GIS SOLUTIONS   Enterprise GIS System - Blantyre</subtitle>
    <logo>assets/images/logo1.png</logo>
    <style>
        <colors>0xFFFFFF,0x333333,0x101010,0x000000,0xFFD700</colors>
        <alpha>0.8</alpha>
    </style>

    <!-- UI elements -->
    <widget left="10"  top="50"    config="widgets/Navigation/NavigationWidget.xml" url="widgets/Navigation/NavigationWidget.swf"/>
    <widget right="-2" bottom="-2" config="widgets/OverviewMap/OverviewMapWidget.xml" url="widgets/OverviewMap/OverviewMapWidget.swf"/>
    <widget right="20" top="55"    config="widgets/MapSwitcher/MapSwitcherWidget.xml" url="widgets/MapSwitcher/MapSwitcherWidget.swf"/>
    <widget left="0"   top="0"     config="widgets/HeaderController/HeaderControllerWidget.xml" url="widgets/HeaderController/HeaderControllerWidget.swf"/>

    <map initialextent="-14083000 3139000 -10879000 5458000" top="40">
        <basemaps>
                       
            <layer label="Aerial"  type="tiled" visible="true" alpha="1"
                   url="http://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer"/>
            <layer label="Topo"    type="tiled" visible="false" alpha="1"
                   url="http://server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer"/>
        </basemaps>
        <operationallayers>
            <layer label="Malawi TA Boundary" type="feature" visible="false"
                   url="http://mymapservice/arcgis/rest/services/FishMerc/MapServer/assets/Data/MW_TA.shp"/>
            <layer label="Study Area" type="feature" alpha="1.0" visible="true" url="assets/Data/StudyArea.shp"/>
            <layer label="Zone" type="feature" visible="true" alpha="0.6" url="assets/Data/Zone.shp"/>
            <layer label="Parcels" type="feature" visible="true" alpha="0.3"
              info="widgets/InfoTemplates/SimpleInfoWinWidget.swf"
                   infoconfig="widgets/InfoTemplates/IWT_BTParcels.xml"
                   url="assets/Data/BTParcel.shp"/>
        </operationallayers>
    </map>

    <!-- widgets organized into widget containers that manage close/open etc -->
    <!-- supported layout property options: horizontal(default)|float|vertical|fix-->
    <widgetcontainer layout="float">
     <widget label="LayerList" left="430" top="90"
                icon="assets/images/i_layers.png"
                config="widgets/LayerList/LayerListWidget.xml"
                url="widgets/LayerList/LayerListWidget.swf"/>
         <widget label="Blantyre Police" left="590" top="280"
                icon="assets/images/MWPolice.png"
                config="widgets/Query/QueryWidget_Louisville_PoliceStations.xml"
                url="widgets/Query/QueryWidget.swf"/>
         <widget label="Query" left="430" top="90"
                icon="assets/images/i_about.png"
                config="widgets/Query/QueryWidget.xml"
                url="widgets/Query/QueryWidget.swf"/>
        <widget label="Bookmarks" left="430" top="90"
                icon="assets/images/i_bookmark_add.png"
                config="widgets/Bookmark/BookmarkWidget.xml"
                url="widgets/Bookmark/BookmarkWidget.swf"/>
        <widget label="Find an address"   left="100" top="90" preload="open"
                icon="assets/images/i_mailbox.png"
                config="widgets/Locate/LocateWidget_US.xml"
                url="widgets/Locate/LocateWidget.swf"/>
        <widget label="Search" left="80" top="280"
                icon="assets/images/i_search.png"
                config="widgets/Search/SearchWidget_BT.xml"
                url="widgets/Search/SearchWidget.swf"/>
        <widget label="Print" left="390" top="400"
                icon="assets/images/i_print.png"
                config="widgets/Print/PrintWidget.xml"
                url="widgets/Print/PrintWidget.swf"/>
    </widgetcontainer>

</configuration>
Tags (2)
0 Kudos
1 Reply
ReneRubalcava
Esri Frequent Contributor
FlexViewer can't natively load shapefile data, but someone made a widget that might help.
http://www.arcgis.com/home/item.html?id=bc6a88cf51364d9ea767347954363d7d
0 Kudos