I'm upgrading some js code and I'm trying to replace this
Xrm.Page.context.prependOrgName("myfile");
with this
var context = Xrm.Utility.getGlobalContext();
context.userSettings.prependOrgName("myfile");
However i'm getting this error
TypeError: Xrm.Utility.getGlobalContext is not a function in functionName
This is a js web resource that I'm trying to run it in.The js is ran onload
Has anyone seen this before?