Select to view content in your preferred language

Move points and add attributes.

4382
11
06-04-2012 01:27 PM
BrianGustafson
Occasional Contributor
Is there a sample that shows how to move points in a graphics layer and display the attributes?  The Graphic object does not have an onClickListener or anything else that allows you to click a graphics.
0 Kudos
11 Replies
AndyGup
Esri Regular Contributor
@mark, hmmm...I'm not clear on what you are trying to accomplish. Can you please provide details on your requirements? And, what would you like to happen in the application once the touch listener event happens?

-Andy
0 Kudos
MarkHorsell
Emerging Contributor
Hi,
Yes, i think i'm trying to achieve the same thing but i've gone about it in a very different way, trying to query the 'dynamic map service layer' instead of the graphics array. This causes an error but i'm not sure why?

Point pointClicked;

pointClicked = mapView.toMapPoint(point.getX(), point.getY());

Query query = new Query();

query.setOutFields(new String[] { "*" });

query.setSpatialRelationship(SpatialRelationship.INTERSECTS);

query.setMaxAllowableOffset(10);

Geometry geom=GeometryEngine.buffer(pointClicked,mapView.getSpatialReference(),100,null);

query.setGeometry(geom);

query.setInSpatialReference(mapView.getSpatialReference());

query.setMaxAllowableOffset(100);

shapesFeatureLayer.selectFeatures(query, ArcGISFeatureLayer.SELECTION_METHOD.NEW, new CallbackListener<FeatureSet>() {
0 Kudos