Hi folks, thanks for any assistance you can offer. Being somewhat new to Arcade I'm sure this is an amateur mistake.
Problem: The first two lines of code work as they should. An IFF statement to remove blank fields, followed by a prefix and suffix added to a field, creating a hyperlink.
Some of the fields (in this case ASBUILTS) need to be removed. I've parsed those out and have a list of 30 which the find and replace with "" will run on.
//works
var ASBUILT = IIF(isEmpty($feature.AsBuiltFileName), "",
"https://asbuilts.ci.missoula.mt.us/water/" + $feature.AsBuiltFileName + ".pdf")
Replace(ASBUILT,"https://asbuilts.ci.missoula.mt.us/water/HH2-A.pdf","")
//doesn't work
var ASBUILT = IIF(isEmpty($feature.AsBuiltFileName), "",
"https://asbuilts.ci.missoula.mt.us/water/" + $feature.AsBuiltFileName + ".pdf")
Replace(ASBUILT,"https://asbuilts.ci.missoula.mt.us/water/HH2-A.pdf","")
Replace(ASBUILT,"https://asbuilts.ci.missoula.mt.us/water/010-A.pdf","")