POST
|
HI @IgorStreltsov1 I came across the exact same error you have posted. Did you manage to find a solution? does layout.exportToPDF rely on a printservice to print to pdf (Based on your comment that your colleague created a test script in python)? If yes how does it determine which print service it is accessing?
... View more
01-07-2021
07:54 AM
|
0
|
0
|
1767
|
POST
|
Hi, I have a 2D widget and a piece of code to get label to show. The layer loads fine however the label isn't. Can anyone advise? _getLabelClass: function () {
var labelSymbol = new TextSymbol();
var defaultPlacement = "above-center"
var json = {
"labelExpressionInfo": { "expression": "$feature.symbolname" },
"useCodedValues": false,
"labelPlacement": defaultPlacement
};
//create instance of LabelClass
var lc = new LabelClass(json);
lc.symbol = labelSymbol; // symbol also can be set in LabelClass' json
return lc;
},
layer = new FeatureLayer(layerSettings.url, options);
const layerInfoArr = [this._getLabelClass()];
layer.setLabelingInfo(layerInfoArr);
this.map.addLayer(layer);
... View more
01-06-2021
01:29 AM
|
2
|
2
|
713
|
POST
|
Hi @DanPatterson , I did however I am happy to report today was alot more stable and the script is running fine now.
... View more
12-17-2020
06:47 PM
|
0
|
0
|
578
|
POST
|
Hi, I am using the pre release 1.8.3 python api for the new workforce. I have code that were working and starting from yesterday, it keep failing randomly in different part of the code with error either 502 or 499 (token required) while trying to automate some work flow on agol (workforce) I have checked agol status and it is green light all the way. Is there anyone else experiencing the same issue? agol = GIS(config.agol_credential['url'], username=config.agol_credential['username'], password=config.agol_credential['password']) wf_project_item = agol.content.get(config.wf_project_itemId) wf_project = workforce.Project(wf_project_item) my code stack trace: wf_project = workforce.Project(wf_project_item) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\project.py", line 71, in __init__ self._update_cached_objects() File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\project.py", line 85, in _update_cached_objects self._cached_workers = {w.id: w for w in self.workers.search()} File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\managers.py", line 734, in search return query_workers(self.project, where) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\_store\workers.py", line 43, in query_workers worker_features = project.workers_layer.query(where, return_all_records=True).features File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\features\layer.py", line 1540, in query record_count = self._query(url, params, raw=as_raw) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\features\layer.py", line 2556, in _query raise queryException File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\features\layer.py", line 2526, in _query postdata=params, token=self._token) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\_impl\_con\_connection.py", line 720, in post force_bytes=kwargs.pop('force_bytes', False)) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\_impl\_con\_connection.py", line 514, in _handle_response self._handle_json_error(data['error'], errorcode) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\_impl\_con\_connection.py", line 536, in _handle_json_error raise Exception(errormessage) Exception: Token Required Token Required (Error Code: 499) Re-Running code again worked and re-running the 3rd time without any code change, it error out again. wf_project = workforce.Project(wf_project_item) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\project.py", line 71, in __init__ self._update_cached_objects() File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\project.py", line 84, in _update_cached_objects self._update_cached_assignment_types() File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\project.py", line 77, in _update_cached_assignment_types self._cached_assignment_types = {a.code: a for a in self.assignment_types.search()} File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\managers.py", line 252, in search return get_assignment_types_v2(self.project) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\_store\assignment_types_v2.py", line 27, in get_assignment_types_v2 return query_assignment_types(project, '1=1') File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\_store\assignment_types_v2.py", line 36, in query_assignment_types assignment_type_features = project.assignment_types_table.query(where, return_all_records=True).features File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\features\layer.py", line 2966, in query record_count = self._query(url, params, raw=as_raw) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\features\layer.py", line 2556, in _query raise queryException File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\features\layer.py", line 2526, in _query postdata=params, token=self._token) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\__init__.py", line 11530, in _token self._hydrate() File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\__init__.py", line 11509, in _hydrate self._refresh() File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\__init__.py", line 11452, in _refresh raise e File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\__init__.py", line 11445, in _refresh dictdata = self._con.post(self.url, params, token=self._lazy_token) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\_impl\_con\_connection.py", line 720, in post force_bytes=kwargs.pop('force_bytes', False)) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\_impl\_con\_connection.py", line 514, in _handle_response self._handle_json_error(data['error'], errorcode) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\_impl\_con\_connection.py", line 536, in _handle_json_error raise Exception(errormessage) Exception: An error occurred. (Error Code: 503) Last try again: wf_project = workforce.Project(wf_project_item) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\project.py", line 71, in __init__ self._update_cached_objects() File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\project.py", line 85, in _update_cached_objects self._cached_workers = {w.id: w for w in self.workers.search()} File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\managers.py", line 734, in search return query_workers(self.project, where) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\apps\workforce\_store\workers.py", line 43, in query_workers worker_features = project.workers_layer.query(where, return_all_records=True).features File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\features\layer.py", line 1540, in query record_count = self._query(url, params, raw=as_raw) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\features\layer.py", line 2556, in _query raise queryException File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\features\layer.py", line 2526, in _query postdata=params, token=self._token) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\_impl\_con\_connection.py", line 720, in post force_bytes=kwargs.pop('force_bytes', False)) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\_impl\_con\_connection.py", line 514, in _handle_response self._handle_json_error(data['error'], errorcode) File "C:\Users\vtay\AppData\Local\ESRI\conda\envs\arcgispro-py3-clone\lib\site-packages\arcgis\gis\_impl\_con\_connection.py", line 536, in _handle_json_error raise Exception(errormessage) Exception: An error occurred. (Error Code: 503)
... View more
12-16-2020
05:04 PM
|
0
|
2
|
607
|
POST
|
Hi @RobertScheitlin__GISP , Yes i can confirm it works for me. Legend is showing "Area Buffer" instead of Override 1
... View more
12-08-2020
07:11 AM
|
1
|
0
|
533
|
POST
|
I am not sure if this is relevant but a colleague managed to find a workaround to implement custom legend for graphic layer const symbol = this._generateFillSymbol(2, new Color([0, 0, 0, 1]), new Color([192, 192, 192, 0.5]));
const geometryBuffer = geometryEngine.geodesicBuffer(geometry, distance, units);
const bufferAreaGraphic = new Graphic(geometryBuffer, symbol);
this.bufferGraphicLayer.add(bufferAreaGraphic);
const simpleJson = {
'type': 'simple',
'label': 'Area Buffer',
'symbol': symbol.toJson()
};
const renderer = new SimpleRenderer(simpleJson);
bufferAreaGraphic.symbol = null;
bufferAreaGraphic._layer.setRenderer(renderer);
bufferAreaGraphic._graphicsLayer.setRenderer(renderer); . Code snippet attached. Hopefully it may help someone as it had helped me.
... View more
12-08-2020
03:12 AM
|
1
|
2
|
535
|
POST
|
Hi did you take the code from the add data widget? cause if you did I don't think it is going to work. You will need to use wab developer. The problem is the path resolution for the string.js. Maybe you can try replacing "dojo/i18n!../nls/strings", to the full path of your string.js. e.g https://xxx.xxx.xxx/strings.js
... View more
12-04-2020
02:32 AM
|
0
|
4
|
2118
|
POST
|
Hi, there isn't an issue. I do it all the time. The title of the item will take precedence. However you are getting a 404 and it is erroring out on string and not string.js. if you take the url that 404 and paste it in a new tab, i can guarantee it is not resolving. I am guessing somewhere in your code or a dependency library is calling out to string something like "dojo/i18n!../nls/strings",
... View more
12-03-2020
08:42 PM
|
0
|
6
|
2124
|
POST
|
Hi @durshe you need to be alot more specific. What is not coming across properly?. those layers were they added to a webmap which is used in wab? or are they added from the add data widget.
... View more
12-03-2020
08:33 PM
|
0
|
0
|
1218
|
POST
|
Hi, Have anyone managed to set the minHeight for a panel in the widget? I am using enterprise portal webappbuilder (by publishing the widget) 10.7.1/ 2.12 wab I tried the before but it did not work. Can anyone advise? _setPanelHeight: function () {
var panel = this.getPanel();
panel.position.height = 600;
panel.setPosition(panel.position);
panel.resizeHandler.minHeight = 50
panel.resizeHandler.minSize= {w:400, h:50}
panel.panelManager.normalizePanel(panel);
},
... View more
12-03-2020
08:29 PM
|
0
|
0
|
289
|
POST
|
Thanks Robert. Not ideal as I am using build in webappbuilder with OOTB attribute widget 😞 but I don't see anyway around this. Cheers
... View more
11-30-2020
02:59 PM
|
0
|
1
|
720
|
POST
|
Hi I have a feature layer that i add through the Add data widget however the time isn't showing in the attribute table. I can see it in the popup however. Can anyone advise what needs to be done?
... View more
11-26-2020
01:39 AM
|
0
|
3
|
750
|
POST
|
Hi, is it possible to make the popup of esri/dijit/editing/Editor resizable? I am open to all suggestions Robert Scheitlin, GISP your opinion would mean a lot to me and really appreciate your help in the community
... View more
10-29-2020
04:40 PM
|
0
|
2
|
957
|
POST
|
Hi, there are a couple of community widgets that can hopefully help you get going ChangeWebMap Widget https://community.esri.com/docs/DOC-7661-savesession-widget
... View more
10-25-2020
05:46 PM
|
2
|
0
|
455
|
Title | Kudos | Posted |
---|---|---|
1 | 03-29-2022 06:53 PM | |
1 | 07-22-2021 07:59 PM | |
1 | 03-30-2022 04:36 PM | |
1 | 10-23-2021 06:49 AM | |
1 | 07-11-2021 11:42 PM |
Online Status |
Offline
|
Date Last Visited |
03-30-2022
06:13 PM
|