Select to view content in your preferred language

view attachments?

4345
12
10-26-2010 09:43 AM
PaulPetersen
Regular Contributor
Just wondering if the new Attachments feature can be consumed in the Flexviewer? I see that it is accessible from REST, so it's possible, right? Are there any existing widget out there that expose Attachments yet?

http://help.arcgis.com/EN/arcgisserver/10.0/apis/rest/index.html
Tags (2)
0 Kudos
12 Replies
AniketWani
Esri Contributor
Have you looked at Edit Widget? It has functionality to add and delete the attachments. In editor attachments is a part of attribute editing.

Edit Widget Doc - http://help.arcgis.com/en/webapps/flexviewer/help/index.html#widgets/edit_widget.htm

Edit widget live - http://help.arcgis.com/en/webapps/flexviewer/live/index.html?config=config-edit.xml

Just wondering if the new Attachments feature can be consumed in the Flexviewer? I see that it is accessible from REST, so it's possible, right? Are there any existing widget out there that expose Attachments yet?

http://help.arcgis.com/EN/arcgisserver/10.0/apis/rest/index.html
0 Kudos
TedChapin
Frequent Contributor
Does it have to be in an Edit widget?  It would be nice if you could view the attachments in a standard identify window, so users can view but not edit the attachments.
0 Kudos
PaulPetersen
Regular Contributor
Does it have to be in an Edit widget?  It would be nice if you could view the attachments in a standard identify window, so users can view but not edit the attachments.


Yes, I think this is what I was getting at. I just want to be able to click on a feature, ideally with the Identify widget, and return all of the attributes, plus the attachments. This would basically mimic ArcMap identify functionality.
0 Kudos
AniketWani
Esri Contributor
This is possible with API component called Attribute Inspector and Attachment Inspector. 
Here are the samples:
http://help.arcgis.com/en/webapi/flex/samples/index.html?sample=AttachmentInspectorInfoWindow
http://help.arcgis.com/en/webapi/flex/samples/index.html?sample=AttributeInspectorInfoWindowViewonly

Specifically for Viewer you need to develop your own widget using those component.
0 Kudos
BarrettStanke
Deactivated User
Are you looking for something like this?
0 Kudos
PaulPetersen
Regular Contributor
Are you looking for something like this?


Yes. 

@aniket: thanks. Just knowing that there's not already a widget for this gives a starting point.
0 Kudos
BarrettStanke
Deactivated User
The above image is a reconfigured InfoTemplate widget that includes attachment links as seen. Everything acts the same as the original except one line needs to be added to the individual config files:

  <?xml version="1.0" ?>
- <configuration>
  <fields>Name,OBJECTID</fields>
<layername>Common Areas</layername>  
<titlefield />
  <linkfield />
  <datefields />
- <!--  field in milliseconds
  -->
  <zoomscale>5000</zoomscale>
  </configuration>
0 Kudos
HaroldBostic
Frequent Contributor
Hello Barrett,

Do you mind Sharing the source code?
0 Kudos
BarrettStanke
Deactivated User
Hello Barrett,

Do you mind Sharing the source code?



Sure.  Just know I didn't write it.  So can't really answer any questions in regards to the coding, just the implementation of it.  Dave Spriggs out of the ESRI - St. Charles office worked with a developer to put it together.

For some reason, it's not working with the Flex 2.2 Update though.  Works fine with the Flex 2.1 version.

All changes are just in the SimpleInfoWinWidget.mxml file, see below.
0 Kudos