Select to view content in your preferred language

Identify Widget for FlexViewer 2.1

60430
266
09-23-2010 11:34 AM
RobertScheitlin__GISP
MVP Emeritus
All,

   I have been waiting for the Final release of the FlexViewer 2.1 before I started to push out some widgets I have been working on.

Here is my Identify Widget for Flex Viewer 2.1. I have tested to ensure proper functioning with FlexViewer 2.1 and am now releasing it to you since the API Team did not get one into the FlexViewer.

Here is the link:

http://www.arcgis.com/home/item.html?id=39cf66d58c234279ba728c50461a1a89

More FlexViewer 2.1 widgets to come stay tuned...
Tags (2)
0 Kudos
266 Replies
RobertScheitlin__GISP
MVP Emeritus
William,

   OK one more piece of info will help. Can you post your main config.xml?
0 Kudos
WilliamRockwell
Occasional Contributor
Sure.

<?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
//
////////////////////////////////////////////////////////////////////////////////
-->
<configuration>
    <httpproxy enabled="false">proxy.php</httpproxy>
    <title>GIS Viewer for Vernon Hills</title>
    <subtitle>... using ArcGIS</subtitle>
    <logo>assets/images/logo.jpg</logo>
    <stylesheet>blackgold.swf</stylesheet>

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

    <map initialextent="-9796914 5192102 -9786999 5200485">
        <basemaps>
            <mapservice label="Streets" type="tiled" visible="false"  alpha="1"                                                       url="http://server.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer"/>

            <mapservice label="Aerial"  type="tiled" visible="true" alpha="1"
                        url="http://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer"/>

            <mapservice label="Topo"    type="tiled" visible="false" alpha="1"
                        url="http://server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer"/>
        </basemaps>

        <operationallayers>

            <layer label="Trees" type="dynamic" visible="false" alpha="1"
  url="http://xxxxxxxxxx/arcgis/rest/services/Trees/MapServer"/>

            <layer label="Parcels" type="dynamic" visible="false" alpha="1"
                url="http://xxxxxxxx/ArcGIS/rest/services/Parcels/MapServer"/>

            <layer label="Village Border" type="dynamic" visible="true" alpha="1"
  url="http://xxxxxxx/ArcGIS/rest/services/VillageBorder/MapServer"/>

            <layer label="Historical Aerial Photos" type="dynamic" visible="true" alpha="1"
  url="http://xxxxxxxx/ArcGIS/rest/services/HistoricalAerials/MapServer"/>

            <layer label="Storm Sewer" type="dynamic" visible="false" alpha="1"
  url="http://xxxxxxxx/arcgis/rest/services/StormSewer/MapServer"/>

     <layer label="Electrical" type="dynamic" visible="false" alpha="1"
  url="http://sxxxxxxxx/arcgis/rest/services/Electrical/MapServer"/>
                  
        </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="Bookmarks"          x="400" y="60" icon="assets/images/i_bookmark.png"
                config="widgets/Bookmark/BookmarkWidget.xml"
                url="widgets/Bookmark/BookmarkWidget.swf"/>
        <widget label="Find an address"   x="70" y="94" preload="open" icon="assets/images/i_target.png"
                config="widgets/Locate/LocateWidget_US.xml"
                url="widgets/Locate/LocateWidget.swf"/>
        <widget label="Search"
                icon="assets/images/i_search.png"
                config="widgets/Search/SearchWidget_Parcels.xml"
                url="widgets/Search/SearchWidget.swf"/>
        <widget label="Draw"
                icon="assets/images/i_draw2.png"
                config="widgets/Draw/DrawWidget.xml"
                url="widgets/Draw/DrawWidget.swf"/>
        <widget label="Print"
                icon="assets/images/i_print.png"
                config="widgets/Print/PrintWidget.xml"
                url="widgets/Print/PrintWidget.swf"/>
        <widget label="Identify" left="330" top="80" preload="closed"
                icon="assets/images/i_info.png"
                config="widgets/Identify/IdentifyWidget.xml"
                url="widgets/Identify/IdentifyWidget.swf"/>
<!--
        <widget label="My first widget"
                icon="assets/images/i_widget.png"
                config="widgets/Samples/HelloWorld/HelloWorldWidget.xml"
                url="widgets/Samples/HelloWorld/HelloWorldWidget.swf"/>
        -->
    </widgetcontainer>

</configuration>
0 Kudos
WilliamRockwell
Occasional Contributor
A guess.... The identify works on layers that are in a feature dataset. It isn't working on stand alone feature classes?
0 Kudos
DustinKosmach1
Deactivated User
Hi Will

Small problem, the widget is only returnsing results for the first field I list.  It will label and make a spot for the fields that I specify, but there is no data there, just data for the first field.

this should probably be in the search thread, but is there an option to keep the graphical search active like you can with the identify tool?
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Dustin,

Small problem, the widget is only returnsing results for the first field I list. It will label and make a spot for the fields that I specify, but there is no data there, just data for the first field.
If you look a couple of post above you will see the work around to this issue is to make sure your comma separated list of fields do not have a space after the comma. Once you edit your xml file ensure your clear your browsers cache. As far as the keepAlive with graphical search no there is no such option currently.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
William,

   I will test to see if your guess pans out.
0 Kudos
deleted-user-NnRwwd8ols89
Deactivated User
Hi Guys, i'm having an issue using multiple feature layers with the this great widget. when i used the widget with a mapserver i had no problems, but since switching to feature layers it's not working as i hoped.

i've got 4 feature layers, but only 1 get's identified, although i get 4 results all for the same point from the same layer. Only the 1 layer (MapServer/0) responds to the tool, but returns 4 identical results.

i'm using arcgis server 9.3.1 and the 2.1.7 widget

i've looked through this post and the fourms but can't seem to find an answer, i imagine upgrading to server 10 would help but that's an option at the moment unfortunatley!

config.xml and IdentifyWidget.xml attached

thanks! Ben
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Ben,

    I tried to reproduce your issue and I was not able to. So my question is in your IdentifyWidget.xml you have names like "33 Bligh St Borehole Logs" is that the actual layer name for http://bnewsd02/ArcGIS/rest/services/gINT_flex_test/MapServer/3 as it is listed in the REST Services directory, Not just the label that you assigned it in the main config?
0 Kudos
deleted-user-NnRwwd8ols89
Deactivated User
Hi Robert,

thanks for getting back to me! i got rid of some redundant commented out code, cleaned my project, restarted the computer overnight and then this morning all was well!

in response to your question yes the layer names that i've called in the IndentifyWidget.xml are exactly as they are in the REST directory.

thanks again for this great widget, and all the support you provide for it!

Ben
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
All,

   A new version is available that fixes some minor issues and now has a FlexViewer 2.1 ans 2.2 compiled version in it.

Enjoy
0 Kudos