Lets say I have 2 pdfs in a share point folder (pdf A and pdf B), and a feature class in pro with 2 attributes (A and B). Is there a way to field calculate the share point hyperlinks into each attribute? So that the hyperlink for PDF A populates into attribute A and the hyperlink for PDF B populates into attribute B?
Generally, when creating a hyperlink as you describe most people have an attribute field for the document name, in your case for each PDF. Hopefully, your PDF names are predictable so you can autogenerate them. For example, in my case I have stations with unique station ids while the PDFs are named like datasheet_XXXX.pdf where xyzx is the station number. Secondly, the prefix for the URL is predetermined, https://myserver/myapp/myreports.
So yes, you can then use string concatenation to build the full URL and save it as a second field. Other option is to just use the ID attribute within an Arcade expression in your Popup to build the URL.
So your A/B attributes would be the ID field; you can ignore the Status bit, and if ID is empty, return null.
The feature class uses three key fields:
Build the report URL: You may also export this calculation for use in other projects.
Example URL where the report ID is the variable: https://www.example.com/report/1
Example Arcade expression used in the field calculation:
var status = Lower($feature.Status);
if (status == "complete") {
return "https://www.example.com/report/" + $feature.ID;
} else {
return null;
}
Note: If the variable identifier is not at the end of the URL, concatenation can be applied using:
"https://prefix" + $feature.ID + "suffix.com"
Status‑driven conditional links: Only records with a status of complete return a constructed URL. All other records explicitly return <Null>.
This status‑driven conditional logic can also be implemented using calculation attribute rules or automated Python workflows if the data updates regularly.