Arcade function GetUser() not found

613
2
Jump to solution
02-21-2023 02:38 PM
Labels (1)
RandallBrown
New Contributor III

How come using the Arcade function GetUser() in a WebMap popup expression I get the following error when testing the expression:

Execution Error:Runtime Error: Function Not Found: GetUser

See the function reference here:  https://developers.arcgis.com/arcade/function-reference/portal_functions/#getuser

I thought one of the cool things about Arcade was that the same code could be used in both desktop and web apps?

Thanks,

0 Kudos
1 Solution

Accepted Solutions
jcarlson
MVP Esteemed Contributor

It depends on what Profile you're in. You can test things out in the Playground to see what functions are or are not available in each.

jcarlson_0-1677019506422.png

I can confirm that the function is indeed available and we use it in some of our Dashboards, but it's not going to show up in every single context.

It may also depend on what version desktop / Portal you're using, as GetUser was only introduced as of Pro 2.7 and Portal 10.9.

- Josh Carlson
Kendall County GIS

View solution in original post

0 Kudos
2 Replies
jcarlson
MVP Esteemed Contributor

It depends on what Profile you're in. You can test things out in the Playground to see what functions are or are not available in each.

jcarlson_0-1677019506422.png

I can confirm that the function is indeed available and we use it in some of our Dashboards, but it's not going to show up in every single context.

It may also depend on what version desktop / Portal you're using, as GetUser was only introduced as of Pro 2.7 and Portal 10.9.

- Josh Carlson
Kendall County GIS
0 Kudos
RandallBrown
New Contributor III

Josh,

Thanks for the reply.  As you point out it looks like my issue has to do with the GetUser() function not being available on the Portal version I am using.  I tested it on a newer instance of portal and found that is available there.

Thanks,

0 Kudos