|
POST
|
I was going to suggest the Erase tool as well, but looks like that also requires an advanced license. I'm not sure if that's a restriction for the OP, but just out of curiosity, any suggestions that wouldn't require that?
... View more
04-29-2020
10:47 AM
|
1
|
6
|
9385
|
|
POST
|
Hi Christian, Unfortunately, to the best of my knowledge, it is not possible to send messages through the ArcGIS Online platform to other members. There is a notification system (i.e. you're notified when you have been added to a group), but not a messaging system. You can use the ArcGIS API for Python to member information for people in your organization (see this blog post by Egge-Jan Pollé). However, I don't think this will work for people outside of your organization. There was a similar question asked by Peter Timmers which looks like it never got answered I found this idea about adding a messaging capability to ArcGIS Online. It's a pretty old post, but maybe it can be revitalized with some comments and up-votes. Or if this doesn't cover exactly what you want, I recommend making a new one! If you do, share it here so we can spread the word Cheers, Katherine
... View more
04-29-2020
06:38 AM
|
2
|
2
|
1667
|
|
POST
|
Turns out there was indeed something wrong with the join, I was referencing the wrong 'globalid' in the second join. Specifically, I had the globalid of the feature layer ("Nutrient_Bank_Monitoring.globalid") rather than the repeat table ("plot_image_repeat.globalid") Here is my full script that works, just in case it might help someone else who comes across this thread: import arcpy
from arcpy import da
import os
#all variables are from a file geodatabase exported from Survey123
featureTable = arcpy.GetParameterAsText(0) # the Feature layer
repeatTable = arcpy.GetParameterAsText(1) # the image_repeat table
attachTable = arcpy.GetParameterAsText(2) # the image_repeat__ATTACH table
fileLocation = arcpy.GetParameterAsText(3) # Output folder location for the photos
repeatLayer = arcpy.MakeTableView_management(repeatTable, "repeatTable_lyr")
attachLayer = arcpy.MakeTableView_management(attachTable, "attachTable_lyr")
arcpy.AddJoin_management(repeatLayer, "parentglobalid", featureTable, "globalid")
arcpy.AddJoin_management(repeatLayer, "plot_image_repeat.globalid", attachLayer, "REL_GLOBALID")
with da.SearchCursor(repeatLayer, ['plot_image_repeat__ATTACH.DATA', 'plot_image_repeat__ATTACH.ATT_NAME', 'plot_image_repeat__ATTACH.ATTACHMENTID', 'Nutrient_Bank_Monitoring.site', 'Nutrient_Bank_Monitoring.plot', 'plot_image_repeat.plot_direction']) as cursor:
for item in cursor:
attachment = item[0] # blob data type
site = str(item[3])
plotNum = str(item[4])
plotDir = str(item[5])
filenum = "ATT" + str(item[2]) + "_" # i.e. ATT531_
filename = site + "_Plot" + plotNum + "_" + plotDir
if attachment != None:
open(fileLocation + os.sep + filename + '.jpg', 'wb').write(attachment.tobytes())
else:
arcpy.AddMessage('No attachment data for ' + site + ", Plot " + plotNum)
del item
del filenum
del filename
del attachment
... View more
04-28-2020
12:03 PM
|
0
|
3
|
5317
|
|
POST
|
You're right, I used an IF statement and confirmed that all of the attributes for the DATA column are None type. The script runs successfully with this IF statement but just returns "No Attachment data" for all rows. with da.SearchCursor(repeatLayer, ['plot_image_repeat__ATTACH.DATA', 'plot_image_repeat__ATTACH.ATT_NAME', 'plot_image_repeat__ATTACH.ATTACHMENTID', 'Nutrient_Bank_Monitoring.site', 'Nutrient_Bank_Monitoring.plot']) as cursor:
for item in cursor:
attachment = item[0] # blob data type
site = str(item[3])
plotNum = str(item[4])
filenum = "ATT" + str(item[2]) + "_" # i.e. ATT531_
filename = site + "_Plot" + plotNum + "_" + filenum + str(item[1]) #i.e. miyagi_creek_Plot6_ATT531_plot_image-20200324-143302.jpg
if attachment != None:
open(fileLocation + os.sep + filename, 'wb').write(attachment.tobytes())
else:
arcpy.AddMessage('No Attachment data')
del item
del filenum
del filename
del attachment So, something must be going wrong with the join. (again, this issue does not occur when I do the joins manually). Any ideas? Thanks again for the help!
... View more
04-28-2020
10:56 AM
|
0
|
5
|
5317
|
|
POST
|
Hi David, thanks for your response. I had to use the makeTableView function because I am working with a table rather than a layer: repeatLayer = arcpy.MakeTableView_management(repeatTable, "repeatTable_lyr") However, then I run into this error, 'NoneType' object has no attribute 'tobytes' So I guess you can't use that function on a table view? If so, how can I access that information to be able to export the photo and assign it a custom file name?
... View more
04-28-2020
10:06 AM
|
0
|
7
|
5317
|
|
POST
|
Yeah, possibly! Did you just recently update to a new version of Pro or something? That might explain why you didn't see this behavior before but now you are.
... View more
04-27-2020
09:59 AM
|
0
|
0
|
4424
|
|
POST
|
That does seem a bit strange. So, after confirming that when you go to the pop-up configuration settings under visualization, it shows the correct Alias here, and the layer configurations have been saved.... Can you try adding the layer to a new web map and see if the aliases will display in the pop-up?
... View more
04-27-2020
09:39 AM
|
0
|
2
|
4424
|
|
POST
|
Are you getting a specific error message when trying to sync?
... View more
04-27-2020
08:14 AM
|
0
|
0
|
1072
|
|
POST
|
Hi Suzanne, First off, just a tip about posting to Geonet, you don't need to write that much text in the title of the question. There is a character limit, so your text will get cut off, which is what happened here. Just use the title as a general synopsis of what your question is about (in this case, something like "Field Alias not being retained after publishing to ArcGIS Online") and then put more details about the situation in the body of the question. Even with the text cut off, I think I can understand what you're getting at. So the pop-up is showing correctly with field aliases used when you look at the visualization tab through the Item Details page, but not when you view the pop-up in a specific web map?
... View more
04-27-2020
07:34 AM
|
0
|
4
|
4424
|
|
POST
|
I am attempting to automate a process of exporting photos from a Survey123 geodatabase and give the output a custom filename, modified from the general script for exporting photos provided by Esri. Here is what I have so far. I am trying to join the Feature Layer, image_repeat table and image_repeat__ATTACH table before exporting the photos so that I can use fields that are in the feature class attribute table in the output file names. import arcpy
from arcpy import da
import os
featureTable = arcpy.GetParameterAsText(0) # the Feature layer
repeatTable = arcpy.GetParameterAsText(1) # the image_repeat table
attachTable = arcpy.GetParameterAsText(2) # the image_repeat__ATTACH table
fileLocation = arcpy.GetParameterAsText(3) # Output folder location for the photos
arcpy.AddJoin_management(repeatTable, "parentglobalid", featureTable, "globalid")
arcpy.AddJoin_management(repeatTable, "Nutrient_Bank_Monitoring.globalid", attachTable, "REL_GLOBALID")
with da.SearchCursor(repeatTable, ['DATA', 'ATT_NAME', 'ATTACHMENTID', 'site', 'plot']) as cursor:
for item in cursor:
attachment = item[0] # blob data type
site = str(item[3])
plotNum = str(item[4])
filenum = "ATT" + str(item[2]) + "_" # i.e. ATT531_
filename = site + "_Plot" + plotNum + "_" + filenum + str(item[1]) #i.e. miyagi_creek_Plot6_ATT531_plot_image-20200324-143302.jpg
open(fileLocation + os.sep + filename, 'wb').write(attachment.tobytes())
del item
del filenum
del filename
del attachment However, I get the following error message - "The value cannot be a table": I have no problem doing the joins manually in ArcMap, so I'm unclear why it won't work in the script. Is it possible to do what I'm trying to do? I am obviously still a python newbie, so many thanks in advance for any help or advice!
... View more
04-26-2020
03:40 PM
|
0
|
11
|
6362
|
|
POST
|
Rickey's answer definitely works if the URL is contained neatly in a different field and you just want to add two different fields together. However, based on your question, it sounds like the URL might be contained within a larger paragraph, and you only want to extract certain text from the paragraph to put in the URL field? If so, I believe Regex (Regular Expressions) or some other more advanced field calculation will be your answer. Are you able to share an example of one of the fields so we can see how it's formatted?
... View more
04-23-2020
05:32 AM
|
0
|
0
|
1370
|
|
POST
|
Do you need super high accuracy for your data collection? If it's not critical, you could lower the accuracy threshold in the app settings for a quick fix.
... View more
04-23-2020
05:20 AM
|
0
|
0
|
1647
|
|
POST
|
Molly Foley, have you thought about using ArcGIS QuickCapture, if speed of collection is really important for this project?
... View more
04-22-2020
08:38 AM
|
0
|
1
|
2403
|
|
POST
|
Hmmm.....good catch! So with "Show Domain and Subtype Descriptions" unchecked, it displays the code in the attribute table as expected, but this setting does not apply to the dropdown when editing the attributes of a feature. I would maybe add this comment to the Idea page I linked to, especially since it says "partially implemented". Might be something they would consider!
... View more
04-21-2020
08:11 AM
|
2
|
9
|
19489
|
|
POST
|
I spoke too soon....I did find this post that explains some (somewhat) newer features that were released with version 2.2 Turning off Coded Domain Value Display in ArcGIS Pro
... View more
04-21-2020
06:58 AM
|
0
|
11
|
19487
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | Thursday | |
| 1 | 2 weeks ago | |
| 1 | 2 weeks ago | |
| 1 | 2 weeks ago | |
| 2 | 2 weeks ago |
| Online Status |
Offline
|
| Date Last Visited |
Friday
|