|
POST
|
I developed an application for my users to do this via Survey123 forms embedded in the experience builder. I had a form for attachments where they could upload and windows for viewing any associated ones when they clicked on an existing feature. Most edits are done in Field Maps but our engineering firm also accesses the Experience to upload inspection reports. I had to set up additional metadata fields for our attachments so I set up a related table just for attachments on my feature class, published it with attachments enabled. I then put in a separate window for updating the attachments in the table format. Not ideal, but since they don't regularly update the attachment information, it works for our purposes. A separate view has an activity form that they can upload photos to record maintenance on a feature. In this experience, they click on a feature, and the "Attachment Metadata" window shows all the associated attachments, which are a combo of PDF and image. Any images when cycling through the attachments will display in the bottom right.
... View more
08-29-2022
01:58 PM
|
2
|
0
|
2881
|
|
POST
|
I could also see you doing a lot of this with Python and string slicing or even using Pandas dataframes. Lots of methods depending on your comfort zone. I also think this could probably be accomplished with a combination of Arcade and Field Calculator.
... View more
08-12-2022
06:32 AM
|
0
|
0
|
1691
|
|
POST
|
Every hour, I have a script that exports a pandas DataFrame to a CSV, and then uses that to overwrite a hosted table in my account. #This gets the hosted table in AGOL
table = gis.content.get('item number here')
#from arcgis.features import FeatureLayerCollection
projects_collection = FeatureLayerCollection.fromitem(table)
#pandas exported to CSV
df4.to_csv(newCSV4, date_format='%m/%d/%Y')
#overwrite old table with new csv data
projects_collection.manager.overwrite(newCSV4) Edit: I do this as it keeps the CSV created as a backup. Every time the script is run, the previous CSV is renamed and stored and then the new CSV takes on the original table name. I only ever keep the current table and the old csv.
... View more
08-12-2022
05:42 AM
|
2
|
0
|
3804
|
|
POST
|
Within the last few weeks, everyone opening ArcMap is suddenly being shown an error about "ArcGIS is currently not connected to online resources." The Sign In and AGOL options are greyed out in the menu, and looking at the portal connection in ArcGIS Administrator has not helped answer any questions. Have tried some of the options here with no success: https://support.esri.com/en/technical-article/000012188 Anyone else have this issue? We're stuck at 10.4 with some 3rd party dependencies right now.
... View more
08-03-2022
07:52 AM
|
0
|
0
|
859
|
|
IDEA
|
I have several departments interested in Hub - many are interested in providing links to additional resources (such as a document in AGOL content) or provide a PDF flyer with more information they may have received from the event holder. It would be nice to have the same HTML customization ability for the event descriptions - particularly support of hyper links. Would be nice to be able to link to an existing document / map / app in my Initiative too.
... View more
07-21-2022
10:58 AM
|
0
|
0
|
803
|
|
IDEA
|
Was just looking to add my first attribute rule and find that it only supports Arcade, not Python! I had wanted to use some regular expressions for formatting my phone numbers and email fields - something I can do on Survey123.
... View more
07-19-2022
11:07 AM
|
0
|
0
|
2905
|
|
POST
|
I haven't actually upgraded yet because I got the attached error when I tried to. Going to have to get in touch with IT.
... View more
06-29-2022
01:26 PM
|
0
|
2
|
9586
|
|
POST
|
What @Luke_Pinner said - Pro upgrades have a nasty habit of messing with your environments. Do you get a message in your interpreter like: Active environment version : 2.7
arcgispro-py3 environment version : 2.6
To create a new environment that is up to date with arcgispro-py3:
1. Generate a list of additional packages installed in your current environment,
with the conda command:
> conda env export > env.yaml
2. (Optional) If you have additional dependencies installed through pip,
find those with pip freeze:
> pip freeze > requirements.txt
2. Create a new environment by cloning arcgispro-py3, and activate it:
> conda create --clone arcgispro-py3 --name my-env --pinned
> activate my-env
3. Add back missing conda packages from your current environment:
> conda env update -n my-env -f env.yaml
4. (Optional) Add back missing packages from pip:
> pip install -r requirements.txt
5. (Optional) Make it the default for the ArcGIS Pro application and the
"Python Command Prompt":
> proswap my-env
The version of the binaries in the active Python environment do
not match the version of the binaries of the ArcGIS Pro application.
... View more
06-28-2022
05:26 AM
|
0
|
0
|
4878
|
|
POST
|
I have a script that takes the current date and subtracts however many days I need off of it, but I'm doing it using a SQL expression. "SystemEndDate IS NULL AND Type = 7 AND (GETDATE() - last_edited_date) <= " + str(days) + "
... View more
06-23-2022
10:37 AM
|
0
|
0
|
2145
|
|
POST
|
So one of the original reasons we went to the ArcMap Parcel fabric was keeping track of parcel history. We are looking at a conversion to ArcPro, and a new request has come up. A genealogist wants an animated history of a parcel for a presentation. I want to know if this is possible. I'm imported our original fabric to ArcPro to test out records and I'm struggling to "backfill" the parcels history - seems like I might consider posting an idea for building out a parcels history for ownership/long searches, but I digress. Is it possible to make a parcel fabric time aware without converting it out of the fabric? Is there a way to animate it in the fabric or can anyone share if they have done it previously, and how?
... View more
05-25-2022
07:15 AM
|
0
|
6
|
2379
|
|
POST
|
I've had some issues with the web experience I've built not consistently displaying the correct view when a button is clicked. I have 4 views that work like 60% of the time but then sometimes it will display the wrong one, and only refreshing the cache seems to (sometimes) fix the issue.
... View more
04-28-2022
10:31 AM
|
0
|
0
|
4703
|
|
IDEA
|
This would be quite useful - especially as we are getting more requests for that sort of information to be collected in situations where we would have used Experience Builder but have to choose a different format due to the lack of tracking information needed for legislative reporting requirements.
... View more
04-18-2022
01:06 PM
|
0
|
0
|
4078
|
|
POST
|
Assuming you're using the online version - yes I had one layer hang on to a previous security sharing setting. I reset everything back to private, and then re-shared it to the group and it seemed to solve the issue for me.
... View more
02-11-2022
11:19 AM
|
0
|
0
|
1998
|
|
POST
|
I learned how to do this a specific way, which is what I am describing. I'm sure someone can come up with a much better way then me, but here is what I have. First, I have a function set up in a separate file called my "Worker". This is the function that will get passed to my pool of workers. This particular function is for creating a one page PDF based off of a map series of parcels. I used this function in lots of other scripts. import os, sys
import arcpy
arcpy.env.overwriteOutput = True
#(Path to your MXD, Path you want the document to be extracted to, name of the page used in the map series)
def publicWorker(mxdPath, outFolder, name):
"""
This is the function that gets called and does the work of exporting the DDP for the UPI specified.
Note that this function does not try to write to arcpy.AddMessage() as nothing is ever displayed. If the cexport succeeds then it returns TRUE else FALSE.
"""
try:
mxdFile = arcpy.mp.ArcGISProject(mxdPath)
cleanName = name.replace("/", "_") #Removes the slash due to it being an escape character
l = mxdFile.listLayouts()[0]
if not l.mapSeries is None:
ms = l.mapSeries
if ms.enabled:
ms.currentPageNumber = ms.getPageNumberFromName(name)
file = os.path.join(outFolder, cleanName)
ms.exportToPDF(file, "CURRENT", resolution=300)
ms.refresh()
del mxdFile
return True
except arcpy.ExecuteError:
# Geoprocessor threw an error
arcpy.AddError(arcpy.GetMessages(2))
report.write("Execute Error:", arcpy.ExecuteError)
except Exception as e:
tb = sys.exc_info()[2]
report.write("Failed at Line %i \n" % tb.tb_lineno)
report.write("Error: {} \n".format(e))
return False Then I have the main multiprocessing script that creates the pool of workers and assigns them my tasks. Here is a portion of the code - Before line 8, my code creates a list of the variables called 'idList' from a feature class that has all of the parcels that were edited and need their PDFs updated. That list is used to create the jobs for the worker pool. import arcpy
import multiprocessing
from PublicWorker import publicWorker
mxdPath =
outFolder =
def createmaps_handler():
jobs = []
for name in idList:
jobs.append((mxdPath,outFolder,name))
arcpy.AddMessage("Public job list has " + str(len(jobs)) + " elements.")
# Create and run multiprocessing pool.
multiprocessing.set_executable(*installpath*, 'pythonw.exe')) # make sure Python environment is used for running processes, even when this is run as a script tool
arcpy.AddMessage("Sending to pool")
cpuNum = multiprocessing.cpu_count() # determine number of cores to use
print("there are: " + str(cpuNum) + " cpu cores on this machine")
with multiprocessing.Pool(processes=cpuNum) as pool:
res = pool.starmap(publicWorker, jobs) # run jobs in job list; res is a list with return values of the worker function
pool.close()
pool.join()
# If an error has occurred report it # count how many times False appears in the list with the return values
failed = res.count(False) # count how many times False appears in the list with the return values
if failed > 0:
arcpy.AddError("{} workers failed!".format(failed))
1))
#makes sure code of the if-statement only executed for main process we start by running script, not the suprocesses created when using multiprocessing in this file
except arcpy.ExecuteError:
# Geoprocessor threw an error
arcpy.AddError(arcpy.GetMessages(2))
print("Execute Error:", arcpy.ExecuteError)
except Exception as e:
# Capture all other errors
arcpy.AddError(str(e))
print("Exception:", e)
if __name__ == '__main__':
createmaps_handler() Eventually, I'd like to improve the error reporting in this, if possible, and I also have been working on a section for reporting how long it takes to run a batch of jobs. Hope this helps! A lot of this was adapted from lessons I learned during the class I have listed above.
... View more
01-24-2022
05:29 AM
|
1
|
0
|
6519
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 06-09-2023 06:45 AM | |
| 2 | 06-28-2021 01:11 PM | |
| 2 | 02-24-2025 08:55 AM | |
| 1 | 07-08-2024 01:49 PM | |
| 1 | 01-24-2023 08:40 AM |
| Online Status |
Offline
|
| Date Last Visited |
10-22-2025
11:15 AM
|