POST
|
Yes. You need to fetch the information once in your application, otherwise it will be null. Once you fetched it, it will be stored. fetchLayerServiceInfo asynchronously fetches the LayerServiceInfo for the specified sublayer. If the LayerServiceInfo has already been fetched, then it will simply return that. Otherwise a network request will be made to fetch it. Once it has been fetched, it will be cached so that getLayerServiceInfo(int) will return it, and so that it won't be fetched more than once.
... View more
01-27-2016
11:01 AM
|
1
|
1
|
525
|
POST
|
getLayerServiceInfo method asked for an integer as sublayerId parameter. public LayerServiceInfo getLayerServiceInfo (int sublayerId) ArcGISDynamicMapServiceLayer | ArcGIS Android 10.2.7 API You may put this line into the loop with sublayerId and test, change: LayerServiceInfo serviceInfo = child.getLayerServiceInfo(); to LayerServiceInfo serviceInfo = child.getLayerServiceInfo(sublayerId);
... View more
01-27-2016
09:48 AM
|
1
|
3
|
525
|
POST
|
Please check out this sample: Nearby Sample | ArcGIS for Developers // Zooms to the current location when first GPS fix arrives. @Override public void onLocationChanged(Location loc) { if (!locationChanged) { locationChanged = true; double locy = loc.getLatitude(); double locx = loc.getLongitude(); Point wgspoint = new Point(locx, locy); Point mapPoint = (Point) GeometryEngine .project(wgspoint, SpatialReference.create(4326), mMapView.getSpatialReference()); Unit mapUnit = mMapView.getSpatialReference() .getUnit(); double zoomWidth = Unit.convertUnits( SEARCH_RADIUS, Unit.create(LinearUnit.Code.MILE_US), mapUnit); Envelope zoomExtent = new Envelope(mapPoint, zoomWidth, zoomWidth); mMapView.setExtent(zoomExtent); } }
... View more
01-21-2016
04:58 PM
|
1
|
0
|
315
|
POST
|
The Query should be executed after layer is loaded. That is to say, LayerDidLoad is the method you are looking for: arcgis-runtime-samples-ios/RootViewController.swift at master · Esri/arcgis-runtime-samples-ios · GitHub Before that, you want to make sure that you have your layer created with your AGSGDBFeatureServiceTable and added to the map, just like this: let featureServiceTable = AGSGDBFeatureServiceTable(serviceURL: url, credential: weakSelf.gdbTask.credential, spatialReference: weakSelf.mapView.spatialReference) let featureTableLayer = AGSFeatureTableLayer(featureTable: featureServiceTable) featureTableLayer.delegate = weakSelf weakSelf.mapView.addMapLayer(featureTableLayer) If it doesn't work for you, would you like to provide your code?
... View more
12-16-2015
03:35 PM
|
1
|
0
|
240
|
POST
|
getFeatureIDs(float x, float y, int tolerance) Identifies the features for the specified device screen coordinates and search tolerance Could you please test getFeature(long oid) to get the Feature specified by its ID? In this way we can test if the featurelayer is added correctly to the map and narrow down the issue.
... View more
12-16-2015
02:56 PM
|
2
|
0
|
238
|
POST
|
I don't think PictureMarkerSymbol has that capability. It's defined in pixel, not a fixed occupation on the map. We should still consider to use PictureFillSymbol. As you already known, If the image is smaller than the fill area, it will be tiled. I would have the following two suggestions for your case: 1.Call setSize(int width, int height) to set the size for the image so that it will fill the area rather than be smaller than it. 2. Call setOffsetX(float offsetX) and setOffsetY(float offsetY) on the image. In this way, even the image is smaller than the area, it will not be tiled. I'm not sure if this meets your requirement because it won't occupy the whole area(I assume you may want the image to stretch when it's not big enough), but at least it will stay at the center.
... View more
10-23-2015
02:09 PM
|
1
|
0
|
433
|
POST
|
Hi Matthias, I tested the sample and it seems I can not reproduce the issue. If I click on the map, there is nothing happening. Did you make any changes to the code? I think the other thing you can do is add more debugging code in the onCallback function and check the queryResult when you clicked the map not feature.
... View more
10-21-2015
11:49 AM
|
1
|
0
|
289
|
POST
|
Hi Ehsan, How did you get the local geodatabase file? Is it created by ArcMap? downloaded from the service within your app? or you downloaded the .geodatabasefile from the service and put it into your phone?
... View more
10-21-2015
11:39 AM
|
1
|
0
|
253
|
POST
|
Hi Stefan, Do you mean you want to place the PictureMarkerSymbol with a fixed pixel size or a fixed occupation on the map? I'm a little bit confused about 50 meters... does it means you want the PictureMarkerSymbol to occupy a 50 meters square/width no matter the zoom level?
... View more
10-21-2015
11:35 AM
|
0
|
1
|
433
|
POST
|
This is an existing bug and development team is aware of it. Please see updates in future releases.
... View more
10-20-2015
10:14 AM
|
1
|
0
|
245
|
POST
|
In your observeValueForKeyPath method, you should not stopDataSource. That will stop the location and you will not be able to display it. I modified your code as follows: -(void) mapViewDidLoad:(AGSMapView*)mapView { // Enable location display on the map [self.mapView.locationDisplay startDataSource]; self.mapView.locationDisplay.autoPanMode = AGSLocationDisplayAutoPanModeDefault; [self.mapView zoomToScale:500.0 animated:true]; } - (void)viewDidUnload { //Stop the GPS, undo the map rotation (if any) if(self.mapView.locationDisplay.dataSourceStarted){ [self.mapView.locationDisplay stopDataSource]; self.mapView.rotationAngle = 0; } self.mapView = nil; } - (IBAction)showCurrentLocation:(id)sender { if(!self.mapView.locationDisplay.dataSourceStarted) [self.mapView.locationDisplay startDataSource]; self.mapView.locationDisplay.autoPanMode = AGSLocationDisplayAutoPanModeDefault; }
... View more
06-18-2015
11:11 AM
|
0
|
1
|
457
|
POST
|
Have your issue reproduced. I noticed that if you remove the layer immediately after adding it, removing won't work. This is because your layer is not loaded yet, so you can not remove it. Try this: mMapView.setOnStatusChangedListener(new OnStatusChangedListener() { @Override public void onStatusChanged(Object o, STATUS status) { if(o==featureLayer) { if(status==STATUS.LAYER_LOADED) { mMapView.removeLayer(featureLayer); } } } }); I'm aware of the black view issue as well, I think that is because you don't have a layer on the mapview. If you have a graphicsLayer or a basemap, it shouldn't show a black view.
... View more
06-17-2015
02:30 PM
|
2
|
0
|
333
|
POST
|
The other way I can think of is using TextSymbol to create a label by yourself. When you rotate the mapView, I think every layer on the map will be redrew as well as the mapview itself.
... View more
06-17-2015
09:21 AM
|
0
|
0
|
544
|
POST
|
Hi Dian, As you seen on this discussion: How to display label infomation There are two ways to do this. If you are working with ArcGISFeatureLayer, then you need to set up labels in your data in ArcMap. You get what you set for labels before publishing, you can not specify fields in your Android code. The second way to do it is using ArcGISDynamicMapServiceLayer. You may already notice that you can operate it with DrawingInfo. LabelingInfo.setLabelExpression(String labelExpression) can help you choose the fields you want to show. Simply by controling the label expression, you can choose which fields to show the values of as labels, concatenate multiple fields, add a custom String, round numerical values, and more using the syntax outlined in the REST specification at http://resources.arcgis.com/en/help/rest/apiref/label.html
... View more
06-15-2015
03:06 PM
|
0
|
1
|
544
|
POST
|
I'm not very clear about your first issue. Does it means it takes a long time to load the three layers? Here is the API reference for AGSFeatureLayer: 10.2.4: AGSFeatureLayer Class Reference You can go through the method and properties and see if there is information you need. If not, you can also do a query on the layer and get the information you want.
... View more
05-20-2015
02:27 PM
|
0
|
0
|
242
|
Title | Kudos | Posted |
---|---|---|
1 | 01-21-2016 04:58 PM | |
1 | 12-04-2014 03:45 PM | |
1 | 10-21-2015 11:49 AM | |
1 | 02-24-2015 10:42 AM | |
1 | 12-16-2015 03:35 PM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|