|
POST
|
Hi @CMcDonald , This can be done with Arcade. Have a look at the example below: // var test1 = $feature["Name of your Field goes here"];
var test1 = "Amenity Accommodation - 14; Flat - 65; Four in a Block - 60; House - 66; Sheltered Accommodation - 38";
var test2 = Replace(test1, "; ", ";");
var list = Split(test2, ";");
var result = Concatenate(list, TextFormatting.NewLine);
return result; The first line is commented ("//"), but explains how you could connect to the field that contains the list. The second line is just to create a variable with the list that you used in your example. On the third line I first replace all the "; " (including the space) for just the ";" to avoid having redundant spaces and the start of each element. On line 4 I use Split to split the text into a list of 5 elements On line 5 the Concatenate function helps to create a text and we combine the elements with a new line. Ths will result in a multililine text:
... View more
01-21-2021
08:57 AM
|
2
|
4
|
4028
|
|
POST
|
Hi @NoahLeimgruber , It looks like you have None (null) values in your Q347 field. You can put an additional validation in the function: def SumAreaInRangeH(oidcurr, dct):
# function to determine catchment area
sumarea = -1
if oidcurr in dct:
# set reference values
h1 = dct[oidcurr][0]
h2 = dct[oidcurr][1]
sumarea = 0
for oid, lst in dct.items():
if oid != oidcurr and lst[0] > h1 and lst[1] < h2:
if lst[2] is not None:
sumarea += lst[2]
return sumarea
... View more
01-18-2021
12:55 PM
|
0
|
0
|
2390
|
|
POST
|
Hi @NoahLeimgruber , As far as I can see you should only have to change the line... flds1 = ("OID@", "H1", "H2", "SHAPE@AREA") into: flds1 = ("OID@", "H1", "H2", "Q347")
... View more
01-18-2021
12:32 PM
|
0
|
3
|
2398
|
|
POST
|
Hi @NathanMichalewicz , You probably have to aggregate the data (on Place, sum the Duration and average the Lat and Long coords) and visualize the resulting table (display XY events) using the coordinates in the table.
... View more
01-18-2021
07:44 AM
|
0
|
0
|
1701
|
|
POST
|
Hi @Alex_Reid and @JohnBrodnicki , Please have a look at the post by @HusseinNasser2 explaining new functionality released in Arcade version 1.12 (available in ArcGIS Pro 2.7) https://community.esri.com/t5/attribute-rules-videos/use-the-getuser-arcade-function-to-return-the-current-user-name/m-p/1016599#M17
... View more
01-15-2021
09:12 AM
|
0
|
2
|
2828
|
|
POST
|
Hi @Miguel-Fernandez , I agree that only sampling a part of the data makes it hard to symbolize all possibilities. Arcade in the symbology profile will not scan the entire database either. If you are able to analyze the data and deduce the possible combinations, you could use https://ago-assistant.esri.com/ to edit the json of the web map and add the missing possibilities in the json. This is a tricky option. Make a copy of the web map before the edit.
... View more
01-15-2021
05:08 AM
|
0
|
0
|
1994
|
|
POST
|
Hi @LaurenMiller78 and @DavidMurray_ODWC , If the data is truly related you can have a look at the FeatureSetByRelationshipName function that allows a more direct access to related data. https://developers.arcgis.com/arcade/function-reference/data_functions/#featuresetbyrelationshipname
... View more
01-15-2021
05:01 AM
|
1
|
1
|
4209
|
|
POST
|
Hi @GretaParis , For future references, it is important to check at what version a functionality was released. If you look at the NextSequenceValue: https://developers.arcgis.com/arcade/function-reference/data_functions/#nextsequencevalue you will see that it was released in version 1.4 of Arcade. In the version matrix: https://developers.arcgis.com/arcade/guide/version-matrix/ you can see that it became available in the next version of Enterprise (10.7 with Arcade version 1.5). It often happens that ArcGIS Pro is updated earlier and easier than ArcGIS Enterprise and that both components are no longer "in sync". This does not have to be a problem but it takes some more time to validate that things configured in Pro will work with once published in Enterprise.
... View more
01-14-2021
02:18 PM
|
1
|
0
|
2674
|
|
POST
|
Hi @BillHeigh , Can you share what data you have (data) and what you are trying? The example I posted should be changed in order to include the field with the phone number. It just represents what the resulting HTML should look like. Not sure if it will show up as a link in the Map Viewer Beta.
... View more
01-14-2021
11:05 AM
|
0
|
1
|
5888
|
|
POST
|
Hi @DonovanC , Earlier on you also mentioned using Python for the field calculation. This should return the same result. def ParseDateTime(tst):
import datetime
dt_format1 = "%d-%m-%Y %H:%M:%S"
dt_format2 = "%m/%d/%y %I:%M:%S %p"
if "-" in tst:
txt = tst[1:20]
dt = datetime.datetime.strptime(txt, dt_format1)
return dt
else:
txt = tst[1:21]
dt = datetime.datetime.strptime(txt, dt_format2)
return dt ParseDateTime(!kml_des!)
... View more
01-14-2021
08:02 AM
|
1
|
1
|
13149
|
|
POST
|
Hi @DonovanC , As far as I understand, the way a date time is shown in ArcGIS Pro depends on the settings of your system: https://pro.arcgis.com/en/pro-app/latest/help/data/tables/date-fields.htm You can validate this using the pop-up and define an expression to return the date and time using the format that you want. An example: return Text($feature["Name of your date field"], "Y-MM-DD HH:mm:ss");
... View more
01-14-2021
07:25 AM
|
1
|
2
|
1980
|
|
POST
|
Hi @DonovanC , Do you have these two additional lines at the end of the expression (to read the attribute and execute the function with the kml description? var txt = $feature["kml_des"];
return Convert2DateTime(txt);
... View more
01-13-2021
03:03 PM
|
0
|
4
|
11183
|
|
POST
|
Hi @DonovanC , Could you try with this function: Function Convert2DateTime(txt) {
var dttxt = Mid(txt, 1, 20);
Console("dttxt: " + dttxt);
if (Find("-", dttxt) == -1) {
// MM/DD/YYYY HH:mm:SS AP
// 0123456789012345678901
// 05/09/20 10:46:41 AM
var y = Number(Mid(dttxt, 6, 2)) + 2000;
var mo = Number(Mid(dttxt, 0, 2)) - 1;
var d = Number(Mid(dttxt, 3, 2));
var mi = Number(Mid(dttxt, 12, 2));
var s = Number(Mid(dttxt, 15, 2));
var ampm = Right(dttxt, 2);
if (ampm == "AM") {
var h = Number(Mid(dttxt, 9, 2));
} else {
var h = Number(Mid(dttxt, 9, 2)) + 12;
}
} else {
// DD-MM-YYYY HH:mm:SS
// 0123456789012345678
// 09-05-2020 10:46:41
dttxt = Left(dttxt, 19);
var y = Number(Mid(dttxt, 6, 4));
var mo = Number(Mid(dttxt, 3, 2)) -1;
var d = Number(Mid(dttxt, 0, 2));
var h = Number(Mid(dttxt, 11, 2));
var mi = Number(Mid(dttxt, 14, 2));
var s = Number(Mid(dttxt, 17, 2));
}
// Date(year, month, day, hours, minutes, seconds)
return Date(y, mo, d, h, mi, s);
}
... View more
01-13-2021
02:36 PM
|
0
|
6
|
11189
|
|
POST
|
Hi @DonovanC , I think I see what is going on. The expression is taking 4 characters for the year, when in this case there are only 2. This should be corrected in the code. The other thing that will probably influence the result is the fact that the time is returned in UTC.
... View more
01-13-2021
02:24 PM
|
0
|
7
|
11190
|
|
POST
|
Hola @FernandoVasquez , En caso que la encuesta está alojada en ArcGIS Enterprise, es posible revisar si la solución menionada acá: https://support.esri.com/en/technical-article/000022129 funcione. En caso que no, recomiendo tomar contacto con soporte para revisar las posibles causas de este error.
... View more
01-13-2021
12:47 PM
|
0
|
0
|
1538
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 01-09-2020 09:26 AM | |
| 6 | 12-20-2019 08:41 AM | |
| 1 | 01-21-2020 07:21 AM | |
| 2 | 01-30-2020 12:46 PM | |
| 1 | 05-30-2019 08:24 AM |
| Online Status |
Offline
|
| Date Last Visited |
Tuesday
|