POST
|
@VivianPham, I think there may be some type of bug going on here. I found another post from a user that was having similar issues. The Fed UC is this week so it's likely Esri employees are pretty busy and haven't had time to respond. Hopefully something can get figured out!
... View more
02-15-2024
11:45 AM
|
0
|
0
|
269
|
POST
|
@AnthonyLatini : any updates on this issue? I think I'm running into the same thing.
... View more
02-01-2024
07:12 AM
|
0
|
0
|
119
|
POST
|
Following up on this with an update: I found some documentation about the Geometry attribute and found out to find this attribute you have to type in "geometry" in the search bar in the Dynamic content window. After trial and error, I found a flow that partially worked: using the trigger "When a record is updated in a feature layer," run the "Get data from feature layer action." After that, run the "Fetch updates, changes, or deletions from feature layer" action and then run the "Create a record in a feature layer" action. The geometry gets written to the feature layer however it creates a polygon for each record in the original feature layer (not just the updated one) and the attributes are incorrect (the attribute is populated with the same value across each record, even those that are different). I have gotten just one record to be written (with the correct attribute) but in that flow there is no geometry associated with the record.
... View more
01-29-2024
11:07 AM
|
0
|
0
|
354
|
POST
|
Oooh, success! After looking at your expression, I modified mine a bit to remove the duplicate lines (e.g. I didn't need to run the FeatureSetByPortalItem twice) and to check if the Secondary Contact existed before I did all of the Secondary Contact information gathering. It worked! I copied my expression here just in case it will help someone else. Appreciate your input! var primPhone = $feature.prim_phone
var secPhone = $feature.sec_phone
var fs = FeatureSetByPortalItem(Portal(Removed for Privacy), 'Removed for Privacy',
0, ['contact_name', 'contact_address1', 'contact_address2', 'contact_city', 'contact_state',
'contact_zip', 'contact_phone', 'contact_email'], false )
var primPhoneID = First(Filter(fs, 'contact_phone=@primPhone'))
var primPhoneConcat = Concatenate("Primary Contact Name:" + TextFormatting.NewLine + primPhoneID.contact_name + " (" + Proper($feature.prim_contact_type) + ")" + TextFormatting.NewLine +
primPhoneID.contact_address1 + (IIf(IsEmpty(primPhoneID.contact_address2), '', TextFormatting.NewLine + primPhoneID.contact_address2)) + TextFormatting.NewLine + primPhoneID.contact_city +
", " + primPhoneID.contact_state + " " + primPhoneID.contact_zip + TextFormatting.NewLine + primPhoneID.contact_phone + TextFormatting.NewLine + primPhoneID.contact_email)
if(secPhone==null) {return primPhoneConcat}
var secPhoneID = First(Filter(fs, 'contact_phone=@secPhone'))
var secPhoneConcat = ("Secondary Contact Name:" + TextFormatting.NewLine + secPhoneID.contact_name + " (" + Proper($feature.sec_contact_type) + ")" + TextFormatting.NewLine +
secPhoneID.contact_address1 + (IIf(IsEmpty(secPhoneID.contact_address2), '', TextFormatting.NewLine + secPhoneID.contact_address2)) + TextFormatting.NewLine + secPhoneID.contact_city +
", " + secPhoneID.contact_state + " " + secPhoneID.contact_zip + TextFormatting.NewLine + secPhoneID.contact_phone + TextFormatting.NewLine + secPhoneID.contact_email)
return primPhoneConcat + TextFormatting.NewLine + TextFormatting.NewLine + secPhoneConcat
... View more
01-25-2024
11:29 AM
|
0
|
0
|
362
|
POST
|
All, I am using Power Automate to help automate a portion of a project's workflow. Unfortunately, I'm running into issues and my Flow is failing. Here's the goal: user updates an attribute in an ArcOnline hosted feature layer. When that attribute is changed to a certain value, we need that feature (polygon and some attributes) to be copied to another hosted feature layer. I've attached screenshots of my current Flow, but am having issues with getting the polygon to be copied. I can get the attributes copied: what happens is a attributed record is created but there is no geometry associated with it. I think it all has to do with the "Geometry" attribute in the "Create a record in a feature layer," but I can't figure out what to put there. I've tried all kinds of combinations. What am I doing wrong? Just a note, too: I haven't added the condition portion of the Flow yet that identifies the attribute and value that should trigger the copying of the record (I want to get the geometry copying portion to work first!). @SeanKMcGinnis @AnthonyLatini
... View more
01-25-2024
10:50 AM
|
1
|
3
|
488
|
POST
|
No luck: I put exactly that in the expression and it's giving me the same response: For those polygons that have both Primary Contact (step3Phone) and Secondary Contact (step7Phone)--that is, they are not Null--the pop-up displays both Primary and Secondary Contact as expected. For those polygons that only have a Primary Contact (step3Phone)--that is, step7Phone is Null--the pop-up displays only a blank line. I have gotten both the Primary and Secondary Contact expressions working individually, so I know it's not something in lines 1-18. I would just like the blank line to disappear if there isn't a Secondary Contact, similar to what happens in lines 7 and 17, where if the second address line is Null it just goes on to the City/State/Zip and doesn't place a blank line in the address block. Appreciate the help...any other suggestions?
... View more
01-22-2024
07:59 AM
|
0
|
0
|
422
|
POST
|
Thanks, Johannes. That makes sense, but it seems I'm still doing something wrong. If there are both Primary and Secondary, both "step4Phone" and "step8Phone" displays (as I want). However, if there is just Primary, nothing displays. Any ideas? I feel like there should be an "else" statement, but I tried that and it didn't work. var step1Phone = $feature.prim_phone
var step2Phone = FeatureSetByPortalItem(Portal('Removed for Privacy'), 'Removed for Privacy',
0, ['contact_name', 'contact_address1', 'contact_address2', 'contact_city', 'contact_state',
'contact_zip', 'contact_phone', 'contact_email'], false )
var step3Phone = First(Filter(step2Phone, 'contact_phone=@step1Phone'))
var step4Phone = Concatenate("Primary Contact Name:" + TextFormatting.NewLine + step3Phone.contact_name + " (" + Proper($feature.prim_contact_type) + ")" + TextFormatting.NewLine +
step3Phone.contact_address1 + (IIf(IsEmpty(step3Phone.contact_address2), '', TextFormatting.NewLine + step3Phone.contact_address2)) + TextFormatting.NewLine + step3Phone.contact_city +
", " + step3Phone.contact_state + " " + step3Phone.contact_zip + TextFormatting.NewLine + step3Phone.contact_phone + TextFormatting.NewLine + step3Phone.contact_email)
var step5Phone = $feature.sec_phone
var step6Phone = FeatureSetByPortalItem(Portal('Removed for Privacy'), 'Removed for Privacy',
0, ['contact_name', 'contact_address1', 'contact_address2', 'contact_city', 'contact_state',
'contact_zip', 'contact_phone', 'contact_email'], false )
var step7Phone = First(Filter(step6Phone, 'contact_phone=@step5Phone'))
if(step7Phone==null){return step4Phone}
var step8Phone = Concatenate("Secondary Contact Name:" + TextFormatting.NewLine + step7Phone.contact_name + " (" + Proper($feature.sec_contact_type) + ")" + TextFormatting.NewLine +
step7Phone.contact_address1 + (IIf(IsEmpty(step7Phone.contact_address2), '', TextFormatting.NewLine + step7Phone.contact_address2)) + TextFormatting.NewLine + step7Phone.contact_city +
", " + step7Phone.contact_state + " " + step7Phone.contact_zip + TextFormatting.NewLine + step7Phone.contact_phone + TextFormatting.NewLine + step7Phone.contact_email)
return step4Phone + TextFormatting.NewLine + TextFormatting.NewLine + step8Phone
... View more
01-19-2024
10:46 AM
|
0
|
0
|
457
|
POST
|
All, I have been stumped with getting an Arcade expression working! In the end, I would like to have an expression that has a Primary Contact (with address information) and, if present, Secondary Contact (with address information). I have the two working separately, but if there is not a Secondary Contact, it returns a blank line. If there isn't a Secondary Contact I'd like it to just be skipped so there isn't an extra line in the pop-up. Below is my expression. Lines 1-8 are for the Primary Contact, lines 9-16 are the Secondary Contact, and line 17 is where my problem lies. If the expression returns false, it appears correctly. If the expression returns true, however, nothing is written. I've tried too many different things to list here--help is much appreciated! var step1Phone = $feature.prim_phone
var step2Phone = FeatureSetByPortalItem(Portal('Removed for Privacy'), 'Removed for Privacy',
0, ['contact_name', 'contact_address1', 'contact_address2', 'contact_city', 'contact_state',
'contact_zip', 'contact_phone', 'contact_email'], false )
var step3Phone = First(Filter(step2Phone, 'contact_phone=@step1Phone'))
var step4Phone = Concatenate("Primary Contact Name:" + TextFormatting.NewLine + step3Phone.contact_name + " (" + Proper($feature.prim_contact_type) + ")" + TextFormatting.NewLine +
step3Phone.contact_address1 + (IIf(IsEmpty(step3Phone.contact_address2), '', TextFormatting.NewLine + step3Phone.contact_address2)) + TextFormatting.NewLine + step3Phone.contact_city +
", " + step3Phone.contact_state + " " + step3Phone.contact_zip + TextFormatting.NewLine + step3Phone.contact_phone + TextFormatting.NewLine + step3Phone.contact_email)
var step5Phone = $feature.sec_phone
var step6Phone = FeatureSetByPortalItem(Portal('Removed for Privacy'), 'Removed for Privacy',
0, ['contact_name', 'contact_address1', 'contact_address2', 'contact_city', 'contact_state',
'contact_zip', 'contact_phone', 'contact_email'], false )
var step7Phone = First(Filter(step6Phone, 'contact_phone=@step5Phone'))
var step8Phone = Concatenate("Secondary Contact Name:" + TextFormatting.NewLine + step7Phone.contact_name + " (" + Proper($feature.sec_contact_type) + ")" + TextFormatting.NewLine +
step7Phone.contact_address1 + (IIf(IsEmpty(step7Phone.contact_address2), '', TextFormatting.NewLine + step7Phone.contact_address2)) + TextFormatting.NewLine + step7Phone.contact_city +
", " + step7Phone.contact_state + " " + step7Phone.contact_zip + TextFormatting.NewLine + step7Phone.contact_phone + TextFormatting.NewLine + step7Phone.contact_email)
return IIf(IsEmpty(step7Phone), step4Phone, step4Phone + TextFormatting.NewLine + TextFormatting.NewLine + step8Phone)
... View more
01-19-2024
08:50 AM
|
0
|
6
|
549
|
POST
|
Thanks for this solution! Also, in case anyone else is having trouble with this, just copy/paste the code directly into the "Geometry" bar--not the f(x) bar in the Expression window that appears when you click in the "Geometry" bar.
... View more
01-05-2024
10:36 AM
|
0
|
0
|
436
|
POST
|
Rylee, thanks for your response! Unfortunately, the three layers/tables need to stay separate as they may not always relate to each other. For example, records in the Outreach Tracking table may not relate to a record in the spatial survey. The purpose of this table is for us to be able to summarize how much/what kind of outreach was done every month. Currently, techs are completing a spreadsheet that contains who they talked to, what kind of outreach it was (phone call, in-person meeting, workshop, etc.), contact information, among other things. Records in this table often aren't referencing a specific piece of land like the spatial survey is, although they can. In the case of the workshop outreach situation, we need to have the record added to the outreach table and also we'd need to add contact information directly to the Landowner Contact table (when the landowner attends the workshop they check in with the tech and the tech adds their information to the contact list). This way, if we end up talking specifically to that landowner about a piece of property late, when we start the landowner survey, the contact information is available and doesn't need to be added again. I've started to play around with the pulldata("@layer") and the link you provided hopefully will help me out--I hadn't found that page before. Let me know if I can expand on more of my workflow or needs; I know it's complicated and I'm not doing a great job of explaining. It's just that there's not one starting point! Annina
... View more
01-02-2024
10:34 AM
|
0
|
0
|
204
|
POST
|
Hey all! I'd appreciate any input you have! I have a project where I have three surveys (1 spatial, 2 non-spatial) that need to be connected. I've created a simplified diagram of what I need--see the attached screenshot. Let me explain; I'll start with the spatial survey, but the workflow doesn't necessarily need to start there: My field techs will be filling out a survey when talking to landowners about a specific piece of property (orange square in the screenshot). The techs will either place a point or polygon on a map, enter landowner contact information, and answer other questions about the property. I would like to create the capability for landowner name lookup, so if we've talked with this landowner before we 1) don't have duplicate contact information and 2) can automatically fill in the survey with the contact information. So, this would mean that we need a non-spatial list of landowner names and contact information (blue circle in the screenshot). If, while filling out the spatial survey the tech finds that the landowner hasn't been in contact with us before, the tech fills in the information in the spatial survey, but the landowner information also gets added to the landowner list. In addition, we need the capability of adding landowner information to this list without submitting a spatial survey (this will happen infrequently). Lastly, we need to keep track of all the times we talk to a landowner (green hexagon in the screenshot). We need to have another non-spatial survey that allows the techs to submit a survey when they talk to or meet with a landowner (similar to a call log). This survey needs to have a record completed along with the spatial survey, if a spatial survey is completed. It also needs to be connected to the first non-spatial landowner contact list and have the contact information automatically complete if it's in the list or add the landowner contact information to the landowner list if it's not included already. My plan is to use ExB to create a webpage that have links to the appropriate survey, depending on the situation. So, if a tech is talking to a new landowner about a specific piece of property, they will click on the link to the spatial survey. But if the tech is following up with a landowner who has questions, they will click on the link to fill out the survey for tracking outreach. We need to have this as streamlined and easy as possible because if it's not, it won't be used. I've been doing a lot of research and talking to my colleagues, and we think it's doable, but now need to start building. However, I don't know where I should begin (or even if this is completely doable!). My plans are to use Survey123 Connect and build the tool as though the user will always have internet connectivity. I also have a much more detailed workflow diagram and have created spreadsheets of survey questions, in which I have made sure those questions that are connected have the same properties so they can be referenced across surveys. Any help is much appreciated. Let me know if you need more information or clarification!
... View more
01-02-2024
06:58 AM
|
0
|
2
|
284
|
POST
|
@TanuHoque Thanks for replying. I have been following the article (I referenced that in my original post). Turns out, though, the "Dynamic Print Service" toolbox that is attached to the article is different than the tools that are named the same in the "Server Tools" toolbox included with ArcPro. Once I downloaded/used the "Dynamic Print Service" toolbox associated with the article, everything worked. Solved!
... View more
11-09-2023
08:45 AM
|
0
|
0
|
552
|
POST
|
I need some help with a custom print template I created. I successfully created and shared a print template for use in WAB, including dynamic text (date printed, sources). However, there is one piece of dynamic text that didn't work: I would like to summarize the acres attribute of a layer visible in the map extent. I've followed the nice tutorial here, but the text where the sum value is blank. I don't know where the issue might be, but I'm wondering about what's in the plain text view of the text element. When I have the layer in the Map frame, the "mapMemberUri" value is populated with a .json string, but as per the instructions, before the layout is exported, the layer needs to be removed. Once that is done, the plain text reads like this: Conserved Acres: <dyn type="table" property="sum" mapFrame="WEBMAP_MAP_FRAME" mapMemberUri="" isDynamic="true" field="activity_acres" decimalPlaces="2" separator="true"/> ac. I don't know where to go from here--any ideas? Thanks! *Update: I modified the link above to reference the correct page I was referring to. Sorry for any confusion.
... View more
11-06-2023
09:08 AM
|
0
|
3
|
651
|
POST
|
Very helpful! I thought nesting meant what you explained and I thought that's what was happening in the revised script. But it ended, so it's not considered nested anymore. Woohoo! As for your question: I'm not sure what was meant here; this was the part in the revised script where everyone was talking about loading all the data into memory first, so I thought I'd try it. Obviously it didn't work... Thanks, all. Appreciate the help!
... View more
09-19-2023
05:33 AM
|
0
|
0
|
127
|
POST
|
I can't thank you all enough for your insights! @HaydenWelch , your edits all make sense. However, when I tried to implement the edits, there were a couple of issues. There was an "EOL: String literal" error after the HUC10_RSTFile_Path after I changed the path to include the "r" at the beginning and removed the duplicate "\" in the path. I reverted back to the original path, which worked. Any idea why this might have errored? Also, why is the "r" solution better? I really like the "loading whole dataset into memory" idea, although the dataset size isn't as large as what you're working with, so it's not extremely necessary. However, I did try to implement it because, why not? There was an error saying that "row" wasn't defined. I thought I had it straight, but I guess I didn't. Here's what I inserted: with arcpy.da.SearchCursor(Point_Buffer_Output, fields) as cursor:
rows = [row for row in rows_to_dict(cursor)]
for row in rows_to_dict(cursor): So, I just wrote it singularly (the whole dataset wasn't loaded into memory). Lastly, the Append didn't work. The fields were added but no shapes/data were appended to the feature class. So, to "fix" my script, I modified the sql expression as @AlfredBaldenweck mentioned. It's running now. However, based on all of the feedback, I know it's not clear/efficient/"good" Python, so I'm interested in your thoughts on my questions above. And last question: in the dialogue between @HaydenWelch and @VinceAngelo , you guys talk about not nesting insert and update cursors. But isn't that what was implemented in my script you modified (lines beginning 115 and 129)?
... View more
09-18-2023
07:49 AM
|
0
|
3
|
795
|
Title | Kudos | Posted |
---|---|---|
1 | 01-25-2024 10:50 AM | |
1 | 07-18-2023 07:33 AM | |
2 | 05-16-2023 12:13 PM | |
1 | 05-16-2023 09:47 AM | |
2 | 12-29-2022 10:03 AM |
Online Status |
Offline
|
Date Last Visited |
02-20-2024
02:01 PM
|