AnsweredAssumed Answered

Determine whether Enterprise Portal or AGOL

Question asked by earnshawgetech on Oct 13, 2020
Latest reply on Oct 15, 2020 by earnshawgetech

Is there a sure fire way to discern whether the users logged in portal is enterprise or AGOL?


I thought about a string test against portalInfo.OrganizationId == "0123456789ABCDEF"


which I believe is always Enterprise - but could this value ever change and as a result break my test?


Or there is portalInfo.PortalName which returns "ArcGIS Enterprise" - but could this be changed too?



Anyway if there is someone who knows more than me, I'm all ears