Xamarin.Essentials: App Information
The AppInfo class provides information about your application.
To start using this API, read the getting started guide for Xamarin.Essentials to ensure the library is properly installed and set up in your projects.
Add a reference to Xamarin.Essentials in your class:
Obtaining Application Information:
The following information is exposed through the API:
// Application Name var appName = AppInfo.Name; // Package Name/Application Identifier (com.microsoft.testapp) var packageName = AppInfo.PackageName; // Application Version (1.0.0) var version = AppInfo.VersionString; // Application Build Number (1) var build = AppInfo.BuildString;
Displaying Application Settings
The AppInfo class can also display a page of settings maintained by the operating system for the application:
// Display settings page AppInfo.ShowSettingsUI();
This settings page allows the user to change application permissions and perform other platform-specific tasks.
Platform Implementation Specifics
App information is taken from the
AndroidManifest.xml for the following fields:
- Build –
- Name -
- VersionString –
We'd love to hear your thoughts. Choose the type you'd like to provide:
Our feedback system is built on GitHub Issues. Read more on our blog.