using Microsoft.Dynamics.ApplicationPlatform.Environment; public str GetInfrastructureHost() { IApplicationEnvironment env = EnvironmentFactory::GetApplicationEnvironment(); str hostUrl = env.Infrastructure.HostUrl; // Trim https:// hostUrl = subStr(hostUrl, 9, strLen(hostUrl) - 8); return subStr(hostUrl, 1, strFind(hostUrl, '.', 1, strLen(hostUrl)) - 1); }
No comments:
Post a Comment