|
POST
|
There is nothing else, it's a simple test file that should load a custom module.
... View more
03-24-2017
04:46 AM
|
0
|
0
|
2072
|
|
POST
|
Hi, I am new to Dojo and ArcGIS JSAPI. I am using version 4.3 and I would like to load a custom module stored in a .js file in a subdirectory. I was trying to do just as this example: http://servicesbeta.esri.com/demos/using-classes-with-javascript/seatgeek-search/ , but it does not work. Dojo is trying to load my custom module from http://js.arcgis.com/4.3/dojo/scripts/MspTiledMapServiceLayer.js instead of using location.pathname.replace(/\/[^/]+$/, "") + "/scripts" <script src="https://js.arcgis.com/4.3/"></script> <script> var dojoConfig = { paths: { scripts: location.pathname.replace(/\/[^/]+$/, "") + "/scripts" } }; require(["scripts/MspTiledMapServiceLayer"], function(MspTiledMapServiceLayer) { new MspTiledMapServiceLayer(); }); </script> This returns a 404 error at http://js.arcgis.com/4.3/dojo/scripts/MspTiledMapServiceLayer.js What am I doing wrong? Thanks a lot for your help. Maxime
... View more
03-23-2017
12:27 PM
|
0
|
5
|
3444
|
|
POST
|
Hi, I am looking for a way to create an Historical Marker programmatically with arcpy v.10.3. The archiving is enabled on a dataset in Oracle SDE. I think, it's related with arcpy Version Toolset, but I can't find the documentation about this. First is it possible to create Historical Markers with arcpy? If yea, any tip about this would be appreciated. Thank you, Maxime
... View more
03-09-2017
12:41 PM
|
1
|
1
|
1587
|
|
POST
|
Hi Andrew, Thanks for your sharings with this issue. Do you encounter the same buggy behaviour with ArcGIS 10.3 and above? Also, do you have an idea how to create a Historical Marker with arcpy? Thank you and have a good day!
... View more
03-09-2017
07:57 AM
|
0
|
0
|
1309
|
|
POST
|
Hi, I am looking for a way to create an Historical Marker programmatically with arcpy. The archiving is enabled on a dataset in Oracle SDE. I think, it's related with arcpy Version Toolset, but I can't find the documentation about this. Thank you, Maxime
... View more
03-09-2017
07:44 AM
|
0
|
1
|
1717
|
|
POST
|
From times to times, ArcGIS Server 10.3 failed to generate token because of an error 201 detailed as Error 201 - LDAP Response read Timeout, timeout used:-1ms. In the logs, I see that the DC used for those failed request are not complete. Only the username was sent to the LDAP server instead of the username and password. This error is happening randomly. Most of the times the generate token service returns the token correctly. Any idea what could be the cause of this?
... View more
02-13-2017
05:45 AM
|
0
|
0
|
1142
|
|
POST
|
I think I misread your question, I though you were actually wanted to post data as json string. I dont know if you can change some parameters in arcgis server but by default the ResponseHeader Content-type is set to "application/x-www-form-urlencoded" when using the json output format.
... View more
01-19-2017
10:42 AM
|
0
|
0
|
1441
|
|
POST
|
Thank you, but the aim is to keep the the newlines. Removing it is not wanted.
... View more
01-19-2017
10:35 AM
|
0
|
0
|
1043
|
|
POST
|
Hi, I am using arcgis server 10.3 and it seems we cannot set the request header Content-type to application/json. See this real example: var postData = {"foo": "bar", "f": "json"}; var xhr = new XMLHttpRequest(); xhr.open("POST", https://mydomain.com/arcgis/rest/services/DEV/testService/GPServer/test/execute , true); xhr.setRequestHeader("Content-type", "application/json"); xhr.onreadystatechange = function () { if (xhr.readyState == 4 && xhr.status == 200) { resolve(JSON.parse(xhr.response)); } } xhr.send(JSON.stringify(postData)); Here is the Response Header: Access-Control-Allow-Origin: http://localhost:8080 Cache-Control: max-age=0,must-revalidate, max-age=60 Connection: Keep-Alive Content-Type: text/html;charset=utf-8 Date: Thu, 19 Jan 2017 18:21:59 GMT Expires: Thu, 19 Jan 2017 18:25:32 GMT Keep-Alive: timeout=15, max=100 Server: Set-Cookie: sto-id-47873-cartod=CHHFBJKMFAAA; Domain=mydomain.com; Expires=Sun, 17-Jan-2027 18:21:59 GMT; Path=/ Transfer-Encoding: chunked Vary: Origin X-Frame-Options: SAMEORIGIN X-XSS-Protection: 1; mode=block access-control-allow-credentials: true Here is the Request Header: Host: mydomain.com User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:50.0) Gecko/20100101 Firefox/50.0 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language: en-US,en;q=0.5 Accept-Encoding: gzip, deflate, br Access-Control-Request-Method: POST Access-Control-Request-Headers: content-type origin: http://localhost:8080 DNT: 1 Connection: keep-alive Pragma: no-cache Cache-Control: no-cache And nothing appears in the posted params. Nothing is posted, nothing in the response neither.
... View more
01-19-2017
10:31 AM
|
0
|
1
|
1441
|
|
POST
|
@James Crandall : There is no such parameter in json.dumps(), at least in python 2.7
... View more
12-21-2016
06:29 AM
|
0
|
2
|
1043
|
|
POST
|
@James Crandall : This is not working. @Joshua Bixby : The work around I have found is to replace the \\n with other characters, for instance <br> before passing it into the SetParameter() and then in the javavscript I replace back the <br> with \n. Off course that's not really satisfying to proceed this way.
... View more
12-21-2016
06:10 AM
|
0
|
5
|
1786
|
|
POST
|
Using raw strings does not help. my_dict = {"key1" : r"test is a string with\nsome escaped characters\nsuch newlines"}
my_json = json.dumps(my_dict)
print(my_json)
>>> '{"key1": "test is a string with\\\\nsome escaped characters\\\\nsuch newlines"}'
arcpy.SetParameter(0, my_json)
Same problem with the json in the javascript console:
{"key1" : "test is a string with
some escaped characters
such newlines"}
... View more
12-21-2016
04:53 AM
|
0
|
10
|
1786
|
|
POST
|
Hi Dan, It seems its an issue with the SetParameter(). I can't find any solution for this case. Is this should be reported to Esri support?
... View more
12-20-2016
04:51 AM
|
0
|
13
|
1786
|
|
POST
|
I have a geoservice that get some text stored from a table in order to return a json string to a javascript client. However, the arcpy.SetParameter() seems to have problem to returns the escaped new lines character ( \\n ) my_dict = {"key1" : "test is a string with\nsome escaped characters\nsuch newlines"}
my_json = json.dumps(my_dict)
print(my_json)
>>> '{"key1": "test is a string with\\nsome escaped characters\\nsuch newlines"}'
arcpy.SetParameter(0, my_json) in the javascript console the response is the following which is not a valid json: {"key1" : "test is a string with
some escaped characters
such newlines"}
Is there a solution?
... View more
12-19-2016
12:14 PM
|
0
|
16
|
3691
|
|
POST
|
Is it possible with arcpy to reproject single x,y coordinates without building a complete geometry object. For instance is it possible to do something like this input = [[-8081441,5685214], [-8081446,5685216], [-8081442,5685219], [-8081440,5685211], [-8081441,5685214]]
output = [arcpy.A_Reproj_Fn((coord[0], coord[1]), source_SR, dest_SR) for coord in input]
I have huge arrays of coordinates to reproject, but for performance issue I dont want to build a geometry object before reprojecting. Thank you for any suggestion!
... View more
12-05-2016
05:15 AM
|
0
|
1
|
909
|
| Title | Kudos | Posted |
|---|---|---|
| 2 | 06-03-2024 10:33 AM | |
| 2 | 05-14-2025 10:45 AM | |
| 1 | 04-12-2022 07:00 AM | |
| 1 | 02-26-2025 05:37 AM | |
| 1 | 01-30-2023 11:12 AM |
| Online Status |
Offline
|
| Date Last Visited |
3 weeks ago
|