Forum Discussion
Inkey_Solutions
Jan 08, 2022Brass Contributor
Create an Environment Variable in Power Apps.
Hello, I am making a Canvas Application in Power Apps in which there arose a situation where I have to make use of environment variables. As far as I know, after referring multiple blogs and vid...
ManiLive
Jan 27, 2022Copper Contributor
Here is a workaround using SharePoint
1. Create a SharePoint list (name it as AppSettings) with a column for each variable you want to configure. For example, "Server", "Version", "Url", etc.
2. Add a single record with the values for each variable
3. From Power Apps, add a SharePoint data source to the list
4. In App->OnStart(),
Set(varAppSettings, First(AppSettings)); //Load the values to a variable5. Now you can access different environment specific values from the app like varAppSettings.Server, varAppSettings.Version, varAppSettings.Url