POST
|
Hello, I installed the latest version but I keep getting the error " ImportError: cannot import name securityhandlerhelper" I am trying the update feature sample as below: from arcresthelper import securityhandlerhelper from arcrest.agol import FeatureLayer from arcrest.common.filters import LayerDefinitionFilter import datetime from datetime import timedelta from arcrest.common.general import local_time_to_online,online_time_to_string if __name__ == "__main__": url = 'URL to Service' sql = 'where clause' dt = local_time_to_online(datetime.datetime.now()) fieldInfo =[ { 'FieldName':'dischrgtyp', 'ValueToSet':'Alert' } ] proxy_port = None proxy_url = None securityinfo = {} securityinfo['security_type'] = 'Portal'#LDAP, NTLM, OAuth, Portal, PKI, ArcGIS securityinfo['username'] = "<User Name>" securityinfo['password'] = "<Password>" securityinfo['org_url'] = "<Org or portal url>" securityinfo['proxy_url'] = proxy_url securityinfo['proxy_port'] = proxy_port securityinfo['referer_url'] = None securityinfo['token_url'] = None securityinfo['certificatefile'] = None securityinfo['keyfile'] = None securityinfo['client_id'] = None securityinfo['secret_id'] = None shh = securityhandlerhelper.securityhandlerhelper(securityinfo=securityinfo) if shh.valid == False: print shh.message else: fl= FeatureLayer( url=url, securityHandler=shh.securityhandler, proxy_port=proxy_port, proxy_url=proxy_url, initialize=True) out_fields = ['objectid'] for fld in fieldInfo: out_fields.append(fld['FieldName']) resFeats = fl.query(where=sql, out_fields=",".join(out_fields)) for feat in resFeats: for fld in fieldInfo: feat.set_value(fld["FieldName"],fld['ValueToSet']) print fl.updateFeature(features=resFeats) thanks, Julie
... View more
10-06-2015
07:11 AM
|
0
|
4
|
4235
|
POST
|
yes, but how do I get to the Attachment of that feature?
... View more
08-20-2015
10:52 AM
|
0
|
1
|
446
|
POST
|
I am trying your sample given here but how do I show the attachment (image) in the popup?
Is there a way to do it? Please help
... View more
08-20-2015
07:35 AM
|
0
|
3
|
3109
|
POST
|
Tom, You said it! We installed the tool in 64bit Python folder and it did it!! thanks a ton:) have a great day!
... View more
04-16-2015
01:48 PM
|
0
|
1
|
521
|
POST
|
Hey Tom, I am using a tool called arcREST( Esri/ArcREST at October2014v1.0Final · GitHub ) in my Python script. On the ArcGIS Server, - we installed arcREST tool - The script ran successfully. - Created a Toolbox and added the Python script. - The toolbox ran successfully - Created a geoprocessing service - Gives error saying "no module named arcrest Failed to execute" - Based on this link , tried using sys.path.append - Still the same error. "no module named arcrest Failed to execute" Any thoughts ? idea ?
... View more
04-16-2015
12:53 PM
|
1
|
3
|
2223
|
POST
|
Is this how I should access the toolbox in a web application? ArcGIS Help 10.1
... View more
04-13-2015
02:03 PM
|
0
|
1
|
522
|
POST
|
Tom, That helped!! I have tied the parameters with the logic....phew. next will get to publishing it to the server.
... View more
04-13-2015
12:51 PM
|
0
|
5
|
2223
|
POST
|
how do I do this? ' The parameters you are filling in have to be tied to the logic you will use to do the analysis you are trying to run.' The function in the script accepts two paramaters and the toolbox lets you enter two parameters. how do I tie it together?
... View more
04-13-2015
12:16 PM
|
0
|
0
|
522
|
POST
|
Hi Tom, Please guide me through this. I am using ArcGIS 10.2 and - At the desired location, I created a new toolbox in ArcCatalog. -Right clicked the toolbox and Added a python script. -Pointed it to my python script. -Created two parameter values Am I in the right path? My python script has a function that takes two parameters def formInfo(Name, activeMile): Now, when I run the toolbox I created, it let me fill two parameters but it doesn't look like it is passing it to the script. The tool gives the message that it ran successfully but it doesn't look like my script with the parameter. In 10.2 , there is also an option to create a new 'Python Toolbox' should I be using this? any thoughts? appreciate your help!!
... View more
04-13-2015
11:42 AM
|
0
|
10
|
2224
|
POST
|
Good idea Tom, I will give that a try. You did that with your ibus app right? Thanks!!
... View more
04-08-2015
01:43 PM
|
0
|
12
|
2224
|
POST
|
If I have a web page form with 'submit' on this simple Javascript API sample, how would I call the Python script on clicking the submit button? any thoughts or ideas?
... View more
04-08-2015
11:31 AM
|
0
|
15
|
14733
|
POST
|
Hi Scott, I downloaded and installed v1 and the script runs fine until deleting features. After printing 'All features removed', pythonw.exe stops working. should I uninstall v2 first? Or is it something else? any thoughts?
... View more
04-01-2015
12:18 PM
|
0
|
0
|
1227
|
POST
|
I am interested in using the downloadable templates of storymaps that lets you login using facebook or other social media account. SOme examples are: Adventure Is In Every Direction Share Your View! Is there a downloadable template available for this? thanks, Julie
... View more
03-30-2015
08:11 AM
|
0
|
1
|
3427
|
POST
|
Hi Scott, I tried your script against ArcREST2 and I get this below error: fl = arcrest.agol.layer.FeatureLayer(url=url,username=username,password=password) TypeError: __init__() got an unexpected keyword argument 'username' any thoughts?
... View more
03-27-2015
06:25 AM
|
0
|
2
|
1227
|
Title | Kudos | Posted |
---|---|---|
1 | 11-29-2021 12:51 PM | |
1 | 08-02-2021 10:53 AM | |
1 | 07-30-2021 07:40 AM | |
1 | 04-14-2021 08:20 AM | |
1 | 04-16-2015 12:53 PM |
Online Status |
Offline
|
Date Last Visited |
02-13-2023
04:04 PM
|