When users selects free trial or try from an app, the user is allowed to use the app up to certain period, which may vary from 7 to 30 days. If the trial period ends, same user cannot use that app anymore unless the app is purchased. Implementing the trial functionality for an app will help the user in marketing the app, and Microsoft Apps Store recommends it. It is recommended to implement these trial functionalities in an app so that user can get a chance to evaluate the app.
Time-Based Trials To set a trial-based app, the user has to set a time or date calculation mechanism in the store app. The store will take care of the app when the trial period ends, so the developer need
not worry about the usage of the app after trial period. While submitting the app in the store the developer has to specify the trial period in days for the app as shown in figure. The trial period starts when the user downloads and installs the app from the store.
Feature-Differentiated Trials When the app trial period expires, the developer can display a message to the customer regarding the expiry of the trial period or send a notification in advance. The developer has to send these reminders using the time-based trial period. To check whether the app is in trial license, the developer can write code as shown in following Code Snippet. Code Snippet: // function to check the licenseinfo private async void fnLicenseInfo() { //license info is retrieved var l = CurrentAppSimulator.LicenseInformation; if (l.IsActive) { // check if there is any trial version, and show appropriate message
In-app purchase means the ability of an app to allow sale or purchase of the app with the help of devices such as a mobile, tablet, or a PC. Many times such in-app purchase is allowed within games and other useful apps that allow the users to pay online and start using all the features of the app. The user can easily purchase such an app without any trouble. The apps are normally activated immediately after in-app purchases.
In the Code Snippet, the user has to declare two elements, namely ListingInformation and LicenseInformation. The listing information will hold all the details of the app. This listing information will hold the app name, description, pricing details; whereas, LicenseInformation will hold the app license details such as trial details, expiry date (if trial), and product availability. The following Code Snippet will get the xml file from the data folder. The xml file must be saved under a folder called data folder. Code Snippet: private async System.Threading.Tasks.Task fnLoadLicenseInfo() { StorageFolder proxyDataFolder = await Package.Current.InstalledLocation. GetFolderAsync(“Data”); StorageFile proxyFile = await proxyDataFolder.GetFileAsync(“storelicense. xml”); await CurrentAppSimulator.ReloadSimulatorAsync(proxyFile); }
This is the most important step for setting up the correct license type for an app developed by the user. To sell an app, the user must analyze and decide the correct pricing that can be charged while selling this app. Price must be competitive than the other similar apps in the market. Another possibility is that, if the user is allowed to try an app for a certain period, he/she will be able to utilize the features of the app.
This is time based trial version of an app. It will have all the features of the app, but after a certain period, i.e. after the trial period, the app will automatically expire and stop execution. The user will not be able to use the app further. The developer of the app can set the period within the range of 1 day to 365 days.
the app up to a certain level until user purchases the full version. For example, if the user installs a trial version of a game app, the app owner will be restricted and will be able to play the game only up to certain levels. Some of the levels in the game will be locked so that the user cannot move and play the next levels.
Generating Revenue Apps/Session 3
13
More ad platforms are available in Windows Store. The developer can develop an advertisement, which pays him/her every time a customer clicks such advertisement. This is known as Pay per Click (PPC). To integrate ads in the store app the developer has to register with Microsoft pubCenter as shown in the following figure.
The developer can manage their account from and Windows Store dashboard. Visual Studio 2013 includes some built-in connection for pubCenter, as shown in the following figure.
The user can use AdControl to display ads in the application. Microsoft has provided an application id for the developers to test the ad control. This application id is as follows:
Licensing an App - Licensing an app in Windows Store is made easy by Microsoft. Most of the functionalities are in-built in the Store apps framework. Create a blank new application and add code given in following Code Snippet to MainPage.xaml. Code Snippet: xmlns=” />xmlns:x=” xmlns:local=”using:TrialApp” xmlns:d=” />xmlns:mc=” mc:Ignorable=”d”> <Grid Background=”{ThemeResource ApplicationPageBackgroundThemeBrush}”> VerticalAlignment=”Top” Margin=”603,300,0,0”/> x:Name=”txtDetail” VerticalAlignment=”Top” Margin=”510,397,0,0”/> VerticalAlignment=”Top” Margin=”500,455,0,0” Click=”btnCalculate_Click” VerticalAlignment=”Top” Margin=”660,455,0,0” Click=”btnDetails_Click”/> </Grid> </Page>
Create an xml file and give name as ‘StoreLicense.xaml’ file to store the license information, as shown in the following figure. This file will hold all the licensing details.
Now, add the following details to the file ‘StoreLicense.xaml’. Write the code given in following Code Snippet with tags to store the license information. Code Snippet: