POST
|
featureLayer.addLoadStatusChangedListener(new LoadStatusChangedListener() { @Override public void loadStatusChanged(LoadStatusChangedEvent loadStatusChangedEvent) { loadStatusChangedEvent.getNewLoadStatus(); } }); I am using this piece of code to know that my layer is failed to load but where can I know the reason of failure, does such a function exist to state it?
... View more
10-28-2021
12:13 AM
|
0
|
1
|
455
|
POST
|
Thanks for the reply Dastan, I already had this style property set in my code but maybe if you can share me the preferences you are using in that xml then that may become helpful.
... View more
05-29-2020
07:13 AM
|
0
|
1
|
1431
|
POST
|
Thanks Colin, I used the graphic constructor to pin the location so it looks like this now. Graphic graphic = new Graphic(x, y);
graphic.setSymbol(pictureMarkerSymbol);
graphic.getAttributes().putAll(attr);
Working as expected.
... View more
11-05-2019
01:52 AM
|
0
|
0
|
1382
|
POST
|
Hi Trevor. Below is the complete code I am using to display the marker. Point point = new Point(x, y, SpatialReference.create(102739)); //point = new Point(x,y); Map<String, Object> attr = new HashMap<>(); attr.put("position", position); PictureMarkerSymbol pictureMarkerSymbol = new PictureMarkerSymbol((BitmapDrawable) getResources().getDrawable(R.mipmap.pin_blue)); Graphic graphic = new Graphic(point, attr, pictureMarkerSymbol); //graphic.computeCalloutLocation(point, mMapView); graphicsOverlay.getGraphics().add(graphic); graphicIds.add(graphicsOverlay.getGraphics().get(graphicsOverlay.getGraphics().size() - 1).getZIndex()); I hope this answers your first question. Yes, I am targeting the Washington DC area, so I will be changing my Spatial Reference to Wgs84. By invalid I mean the markers are not placed on the expected location. Thanks.
... View more
11-05-2019
01:37 AM
|
0
|
1
|
1382
|
POST
|
Hello team esri. I am using arcgis-runtime library 100.4.0 on android and I have tried several ways to map my marker on the points. Point point = (Point) GeometryEngine.project(new Point(x, y), SpatialReference.create(102739));
Point point = new Point(x, y, SpatialReference.create(102739));
Point point = new Point(x, y); and finally I am doing this: graphicsOverlay.getGraphics().add(graphic);
graphicIds.add(position);
The value I am getting from point = Point: [38.915019, -77.009938, 0.000000, NaN] SR: 102739
but all are pointing to invalid coordinates.
Testing on device Samsung S9. Target sdk 28 and min sdk 24.
Thanks.
... View more
11-04-2019
11:52 PM
|
0
|
5
|
1663
|
POST
|
Hello team Esri, have you come to any conclusion regarding this issue? It has been 5 months now. Thanks.
... View more
09-10-2019
11:38 PM
|
0
|
0
|
1431
|
POST
|
No, I am still unable to identify that what is the difference between the first and the other runs. I think I am not using any local geodatabase because every time I have to fetch the layers from a url. Please let me know if you have any leads. Thanks.
... View more
09-10-2019
11:35 PM
|
0
|
0
|
1431
|
POST
|
Here you go. private void displayPopup(Graphic graphic) {
Callout mapCallout = mMapView.getCallout();
Map<String, Object> atts = graphic.getAttributes();
String customId = (String) atts.get("customid");
String name = (String) atts.get("name");
String address = (String) atts.get("address");
String date = (String) atts.get("date");
String lotNumber = (String) atts.get("lotnumber");
String inspectiontype = (String) atts.get("inspectiontype");
/*if(lotNumber==null || lotNumber.equals(""))
lotNumber= "-";*/
View convertView = getLayoutInflater().inflate(R.layout.map_infowindow, null);
TextView textViewRecordCustomID = convertView.findViewById(R.id.textViewRecordCustomID);
TextView textViewName = convertView.findViewById(R.id.textViewName);
TextView textViewDate = convertView.findViewById(R.id.textViewDate);
TextView textViewAddress = convertView.findViewById(R.id.textViewAddress);
TextView textViewInspectionType = convertView.findViewById(R.id.textViewInspectionType);
TextView textViewLotNumber = convertView.findViewById(R.id.textViewLotNumber);
textViewDate.setVisibility(View.GONE);
textViewName.setVisibility(View.GONE);
textViewRecordCustomID.setText("");
textViewName.setText("");
textViewDate.setText("");
textViewAddress.setText("");
textViewInspectionType.setText("");
textViewLotNumber.setText("");
textViewRecordCustomID.setText("");
textViewRecordCustomID.setText("");
//TextView textViewLastInspectionDate = (TextView)convertView.findViewById(R.id.textViewLastInspectionDate);
textViewRecordCustomID.setText(customId);
textViewName.setText(name);
textViewDate.setText(date);
textViewAddress.setText(address);
textViewInspectionType.setText(inspectiontype);
textViewLotNumber.setText("Lot Number:" + lotNumber);
convertView.setTag(R.string.id_position, atts.get("position"));
convertView.setOnClickListener(v -> openDetail((int) v.getTag(R.string.id_position), true));
// Here, we populate the Callout with the attribute information
// from the report.
//mapCallout.off(0, 0);
mapCallout.setLocation(selectedPoint);
mapCallout.setShowOptions(new Callout.ShowOptions(true, true, true));
//mapCallout.setMaxWidth(1000);
//mapCallout.setMaxHeight(400);
mapCallout.setStyle(new Callout.Style(this, R.xml.mycalloutprefs));
mapCallout.setContent(convertView);
Geometry graphicGeom = graphic.getGeometry();
if (graphicGeom instanceof Point) {
mapCallout.show(convertView, (Point) graphicGeom);
} else {
int selectedX = 1;
int selectedY = 1;
mapCallout.show(convertView, mMapView.screenToLocation(new android.graphics.Point(selectedX, selectedY)));
}
//mapCallout.show();
}
... View more
04-15-2019
05:04 AM
|
0
|
0
|
1431
|
POST
|
I have to restart my Esri map or restart app to show map callout but the map callout is actually present in the desired location but never displays in the first launch of the app. Here is my code. mMapView = findViewById(R.id.map);
//ArcGISMap map = new ArcGISMap(SpatialReference.create(2868));
ArcGISMap map = new ArcGISMap(Basemap.createStreetsVector());
mMapView.setMap(map);
//new Handler().postDelayed(()->mMapView.setMap(map), 3000);
mMapView.getGraphicsOverlays().add(graphicsOverlay);
PictureMarkerSymbol pictureMarkerSymbol = new PictureMarkerSymbol((BitmapDrawable)getResources().getDrawable(R.mipmap.pin_blue));
Map<String, Object> attr = new HashMap<>();
attr.put("position", i); attr.put("name", record.getName()); Graphic graphic = new Graphic(point, attr,pictureMarkerSymbol); graphicsOverlay.getGraphics().add(graphic);
... View more
04-12-2019
05:07 AM
|
0
|
10
|
2085
|
POST
|
I stopped dismissing the map when the activity onstop() was calling and now its working fine. Thanks.
... View more
04-08-2019
03:08 AM
|
0
|
0
|
955
|
POST
|
Yeah sure. Esri works fine when I first navigate to the Esri activity but when I return to Esri activity from any activity it gives the same crash every time as I stated earlier. I tested this on Samsung S8 and Samsung S9. Below is the xml file content. <RelativeLayout
android:id="@+id/relativeLayoutMap"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<com.esri.arcgisruntime.mapping.view.MapView
android:id="@+id/map"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
<LinearLayout
android:id="@+id/linearlayoutMappOption"
android:orientation="vertical"
android:layout_width="160dp"
android:layout_marginBottom="500dp"
android:layout_height="wrap_content"
android:layout_margin="0dp"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:visibility="visible"
>
<ImageButton
android:id="@+id/imageButtonLocate"
android:layout_width="124dp"
android:layout_height="58dp"
android:layout_gravity="right"
android:src="@mipmap/icon_map_locate"
android:scaleType="fitCenter"
android:layout_margin="1dp"
android:background="@android:color/transparent"
>
</ImageButton>
<ImageButton
android:id="@+id/imageButtonMapLayers"
android:layout_width="124dp"
android:layout_height="58dp"
android:src="@mipmap/icon_map_layers"
android:scaleType="fitCenter"
android:layout_margin="1dp"
android:layout_gravity="right"
android:background="@android:color/transparent"
>
</ImageButton>
<ImageButton
android:id="@+id/dummy"
android:layout_width="124dp"
android:layout_height="28dp"
android:background="@android:color/transparent"
>
</ImageButton>
</LinearLayout>
<ProgressBar
android:id="@+id/progressBarMap"
android:layout_width="50dip"
android:layout_height="50dip"
android:layout_centerInParent="true"
android:visibility="gone"
/>
</RelativeLayout>
... View more
04-03-2019
02:30 AM
|
0
|
2
|
955
|
POST
|
2019-04-02 15:01:49.768 569-770/ E/AndroidRuntime: FATAL EXCEPTION: GLThread 10588 Process: PID: 569 com.esri.arcgisruntime.ArcGISRuntimeException: Invalid argument at com.esri.arcgisruntime.internal.jni.CoreGeoView.nativeResize(Native Method) at com.esri.arcgisruntime.internal.jni.CoreGeoView.a(SourceFile:581) at com.esri.arcgisruntime.internal.h.b.g.a(SourceFile:1077) at com.esri.arcgisruntime.mapping.view.GeoView$b.onSurfaceChanged(SourceFile:1308) at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1555) at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1270)
... View more
04-02-2019
03:07 AM
|
0
|
4
|
1467
|
POST
|
I removed a certain dependency from my app which fixed the issue.
... View more
04-01-2019
05:10 AM
|
0
|
0
|
617
|
POST
|
I am facing problems in migration from older to newer version of Esri maps. This problem didn't arise when I tried to run it on a test project where I never included the older sdk of Esri. The problem is that when I add the newer dependency and remove the old one it seems to be working fine but on runtime when it tries to inflate the runtime version map from xml it throws an error. java.lang.RuntimeException: Unable to start activity android.view.InflateException: Binary XML file line #182: Binary XML file line #182: Error inflating class com.esri.arcgisruntime.mapping.view.MapView Caused by: android.view.InflateException: Binary XML file line #182: Binary XML file line #182: Error inflating class com.esri.arcgisruntime.mapping.view.MapView Caused by: android.view.InflateException: Binary XML file line #182: Error inflating class com.esri.arcgisruntime.mapping.view.MapView Caused by: java.lang.reflect.InvocationTargetException Caused by: java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file tnMVBDjuD2icZChUilHp6A==/split_lib_resources_apk.apk!/lib/arm64-v8a, v8a,/system/lib64]]] couldn't find "libruntimecore.so" I have tried to refresh all Gradle dependencies of the project, performed clean build and rebuilt project but nothing worked. Thanks.
... View more
03-29-2019
04:21 AM
|
0
|
1
|
991
|
Online Status |
Offline
|
Date Last Visited |
10-28-2021
02:01 AM
|