POST
|
We recently upgraded our portal from 10.6. to 10.7.1 and I'm having issues with new lines and dynamic text in existing custom print services published in 10.6. The print service is used in an existing ESRI JS API 4.11 print widget. I tried recreating and publishing a new version of the print service but it does the same thing. I have a title block and a note section that is no longer recognizing new lines and instead adds a white square. Example: This is what it should look like: Has anyone else run into this problem and if so what do I need to do to fix it? Thanks, -Justin
... View more
10-25-2019
06:25 AM
|
0
|
0
|
389
|
POST
|
Great to hear, thanks for addressing the issue and keeping us updated.
... View more
07-01-2019
09:54 AM
|
0
|
0
|
1046
|
POST
|
OK thanks, I republished the service with feature classes instead of shapefiles and that fixed it. -Justin
... View more
05-15-2019
08:12 AM
|
0
|
0
|
611
|
POST
|
Robert, Thanks for the reply. How do I check this? I published the map service with ArcMap 10.6.1 to Enterprise 10.6.1. My source files were shapefiles, could that be the issue?
... View more
05-15-2019
07:39 AM
|
0
|
2
|
611
|
POST
|
I'm referencing a portal item map built in ArcEnterprise and I'm trying to set up layer searching. I've configured the layer search settings in the portal map settings as seen here: The only layer that returns the search suggestions panel in my JS 4.11 app is the 'SC DOT Projects' layer: All of the other layers should also return suggestions, as they each have a feature with an 'r' in them, but it doesn't work and I'm not sure what I'm doing wrong. Technically the search works for the layers, as it will search if I select the dropdown arrow, select the individual search layer, and then hit enter but no search suggestions will display which makes it hard for a user to properly search. The 'SC DOT Projects' map service isn't a service that I've published, SC DOT did, so maybe something is wrong with my map service settings? Thanks y'all, -Justin
... View more
05-15-2019
07:25 AM
|
0
|
4
|
804
|
POST
|
Robert, As always you are the man! Thanks so much! -Justin
... View more
04-30-2019
06:50 AM
|
0
|
1
|
737
|
POST
|
I've created a statistics query tool that uses a Tabulator table to display the selected results. When the user clicks on a row it will zoom to the appropriate feature. See screenshot: I'd also like to open the selected feature's popup when they click on it, and I've gotten it to work, however it will only display the text literal instead of the feature attributes. See screenshot: Here is my code, rowClick is from Tabulator. rowClick: function(e, row) {
// WHEN ROW IS CLICKED, ZOOM TO SELECTED FEATURE
app.activeView.whenLayerView(app.layerToBeQueried).then(function(layerView) {
var query = app.layerToBeQueried.createQuery();
query.where = "StationShortName = " + "'" + row._row.data.StationShortName + "'";
query.outSpatialReference = app.activeView.spatialReference;
query.returnGeometry = true;
app.layerToBeQueried.queryFeatures(query).then(function(results) {
var selectedFeature = results.features[0];
app.activeView.goTo({
target: selectedFeature.geometry,
zoom: 20
});
app.activeView.popup.open({
location: selectedFeature.geometry,
content: selectedFeature.sourceLayer.popupTemplate.content[0].text
})
});
});
}, I've tried creating a PopupTemplate + TextContent and it did the same thing. Can someone please tell me what I'm doing wrong? Thanks, -Justin
... View more
04-30-2019
06:07 AM
|
0
|
3
|
911
|
POST
|
Thanks for the reply and the update, I'll comment out this code for now and wait for the fix in the next release. No biggie. Thanks again! -Justin
... View more
04-29-2019
09:15 AM
|
1
|
0
|
604
|
POST
|
I've created a button that the user can click to clear their current measurement. It works just fine for the DirectAreaMeasurement3D tool...I click the button, the clearMeasurement() method fires, it clears the measurement and resets the widget. However, whenever I do the same with DirectLineMeasurement3D, the clearMeasurement() method seems to be acting like the newMeasurement() method...it clears the drawing but always asks the user to start a new measurement. Can someone please let me know what I'm doing wrong? app.clearMeasureButton3d.addEventListener('click', function(){
try {
app.measurementWidget_3D.viewModel.clearMeasurement();
} catch (error) {
console.log('Error message clearMeasureButton3d: ', error.message);
}
}); Here is the code that creates the appropriate widget: function setActiveWidget_3dmeasurewidget(type) {
switch (type) {
case "distance":
app.measurementWidget_3D = new DirectLineMeasurement3D({
view: app.activeView,
unit: "imperial"
});
if (app.measurementWidget_3D.view === null) {
app.measurementWidget_3D.view = app.activeView;
}
var distanceDiv = document.createElement("div");
app.measurementWidget_3D.container = distanceDiv;
document.getElementById("3DMeasureOutput").appendChild(distanceDiv);
setActiveButton_3dmeasurewidget(
document.getElementById("distanceButton")
);
break;
case "area":
app.measurementWidget_3D = new AreaMeasurement3D({
view: app.activeView,
unit: "imperial"
});
var distanceDivArea = document.createElement("div");
app.measurementWidget_3D.container = distanceDivArea;
document.getElementById("3DMeasureOutput").appendChild(distanceDivArea);
setActiveButton_3dmeasurewidget(document.getElementById("areaButton"));
break;
case null:
if (app.measurementWidget_3D) {
app.activeView.ui.remove(app.measurementWidget_3D);
app.measurementWidget_3D.destroy();
}
break;
}
}
... View more
04-29-2019
06:59 AM
|
0
|
3
|
736
|
POST
|
No, I did not change the symbol.This is a sample from my 4.10 code if (app.sketchWidget.activeTool === 'point') {
//if statements control whether to get color value from html color picker or dropdown menu. HTML color picker used in all browsers except for IE, which uses the dropdown menu
if (pointSymbolButton_color_IE_styles.getPropertyValue('display') === 'block') {
app.pointSymbol_sketchwidget.color = pointSymbolButton_colorValue_IE;
} else {
app.pointSymbol_sketchwidget.color = pointSymbolButton_colorValue;
}
if (pointSymbolButton_outlinecolor_IE_styles.getPropertyValue('display') === 'block') {
app.pointSymbol_sketchwidget.outline.color = pointSymbolButton_outlineColorValue_IE;
} else {
app.pointSymbol_sketchwidget.outline.color = pointSymbolButton_outlineColorValue;
}
app.pointSymbol_sketchwidget.style = pointSymbolButton_styleValue;
app.pointSymbol_sketchwidget.size = pointSymbolButton_sizeValue;
app.pointSymbol_sketchwidget.outline.width = pointSymbolButton_outlineWidthValue;
pointStyles.style.display = 'block';
polylineStyles.style.display = 'none';
polygonStyles.style.display = 'none';
} app.pointSymbol_sketchwidget is the simple marker symbol used by app.sketchWidget's sketch view model pointSymbol property.
... View more
04-08-2019
05:09 AM
|
0
|
0
|
1046
|
POST
|
Sascha...you are the man! Cloning it works perfectly! And to answer your question, yes. In 4.10 I did not need to clone the viewModel's point/polyline/polygon symbol for the code to work. Thank you again for your quick replies and for solving my issues!
... View more
04-04-2019
12:53 PM
|
0
|
2
|
1046
|
POST
|
Thanks for the quick reply and confirmation that it is a bug. Your work around is what I needed. There is another quirk that I found with the new sketch widget, can you please see if you can reproduce this because I think it is a bug as well. In 4.10 I added basic html input color pickers and input sliders to the Sketch widget to allow the user to change the color, style, width, outline width, etc for the widget. It is all done with basic javascript inside of a 'watchUtils.when' on the sketchWidgets 'activeTool' property, simply get the input elements by ID, store their current value in a variable, and then assign that variable to the SketchViewModel's pointSymbol/polylineSymbol/polygonSymbol properties, for example: sketchViewModel.pointSymbol.color = [insertNewColorValueFromInputElementHere] Basically, every time the user clicks one of the sketch widget buttons the first thing that happens is that it fetches the current value in the input elements and overwrites the appropriate sketchViewModel property. Worked like a charm...until I tried to do it with 4.11 You can change the value in the color picker, slide the slider, change everything, but it never updates the actual graphic drawn on the screen, it always keeps the default styling from the sketchViewModel. However, and this is why I think it is a bug, when I log the sketchViewModel's properties they clearly show that they are being properly updated with the new value from the input color pickers...however the graphic that is actually drawn doesn't change color/width/size/etc. For example: Lets say the sketchViewModel's default point symbol color is 'rgb(1,2,3)'. The user clicks the 'draw point' button and a point is drawn with the color 'rgb(1,2,3)'. The user then changes the color input for the point symbol's color to a value of 'rgb(25,50,100)' and then clicks the 'draw point' button to sketch a new point. When I log the sketchViewModel at that time it will log 'sketchViewModel.pointSymbol.color = 'rgb(25,50,100)', indicating that the code worked as expected....except the color of the graphic that is drawn is still 'rgb(1,2,3)'. I've even logged the sketchViewModel in an 'sketchWidget.on('create',function(event){if event==='complete'}) statement, thinking that maybe something has changed in the onComplete method that overwrites the sketchViewModel's color value...but no. Even in the onComplete method it logs 'sketchViewModel.pointSymbol.color='rgb(25,50,100)'....even though the graphic on screen is still being drawn as 'rgb(1,2,3)'. I'm at my wits end trying to figure this out so I'm wondering if you can reproduce it on your end and confirm that it is indeed a bug? And, if it isn't a bug, please help me figure out what I'm doing wrong. Thanks again!
... View more
04-04-2019
06:48 AM
|
0
|
4
|
1046
|
POST
|
I have an app created that allows users to swap views between 2D and 3D, similar to the sample app used for the Calcite Maps Style Explorer. Now that the Sketch widget is available in 3D in 4.11 I'm trying to get the widget synced between views however I'm running into an issue. When I first create the widget in 2d, everything works as expected. You can create sketch graphics and you can click on the graphic to start updating it. Here is a sample of how my code looks when the widget is first created in 2d: var sketch = new Sketch({ view: mapView, layer: graphicsLayer }) When the user switches views I assign the sketch widget view to the new view, SceneView, like so: sketch.view = sceneView This works to an extent. The sketch widget is still visible on the map and will let you sketch new graphics. However you can no longer click on a created graphic to update/transform it, it is like the hitTest no longer works. This problem persists when the user switches back to 2d. As before, I assign the sketch widget view back to mapView, like so: sketch.view = mapView And now the same problem occurs. You can add in new graphics but you can no longer click on a graphic to update/transform it. It only adds the graphic to the screen and nothing more. The only time that the widget fully works as expected is when the app is first loaded. After that, once the user switches views, it will only allow the user to sketch new graphics and they can no longer select a graphic to update/transform/delete. Can someone point me in the right direction and tell me what I'm doing wrong? Has anyone figured out how to sync the new Sketch widget yet so you don't lose functionality when changing views?
... View more
04-02-2019
01:08 AM
|
0
|
8
|
1638
|
POST
|
All, I'm developing an app using 4.x that allows the user to swap between 2D and 3D views. Everything works fine on all browsers except that after you switch from 2D to 3D and then back to 2D the navbar containing the home/zoom/pan buttons disappears when using Internet Explorer 11. This doesn't happen in Chrome/Firefox/Opera/Edge and I think I've discovered the root cause of the issue: the parent div that holds the 'esri-ui-top-left' div is empty after switching back to 2D from 3D See attached screenshots When the page is first loaded the 'esri-ui-inner-container esri-ui-corner-container' div houses the 'esri-ui-top-left' div, the div that holds the navbar. You can see this in the 'before.jpg' attachment. After you switch the view to 3D and then back to 2D again the 'esri-ui-inner-container esri-ui-corner-container' div is now empty, meaning there is nowhere to append the navbar div. You can see this in the 'after.jpg' attachment. Has anyone figured out a work-around to this issue? Is this a known bug that has been reported? If not do I need to report it, and how? See an old, unresolved topic here: GeoNet Discussion - Losing ui widgets after switch 2d/3D (maquette widget and more)
... View more
11-09-2018
09:07 AM
|
0
|
0
|
494
|
Title | Kudos | Posted |
---|---|---|
1 | 04-29-2019 09:15 AM |
Online Status |
Offline
|
Date Last Visited |
04-10-2023
07:25 PM
|