PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
  • Principle and implementation
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
inAppCheckSubscription (Function)
In french: inAppVérifieAbonnement
When starting the iOS application, checks whether the In-App subscriptions have been renewed.
Example
// Initialization code of project
inAppCheckSubscription(CheckSubscription)
PROCEDURE CheckSubscription(bSuccess is boolean, Product is inAppProduct)
IF NOT bSuccess THEN
ToastDisplay(ErrorInfo())
RETURN
ELSE
// Call the inAppListPurchase function
// to check the start and end dates of subscription
END
Syntax
inAppCheckSubscription(<WLanguage procedure>)
<WLanguage procedure>: Procedure name
Name of WLanguage procedure ("callback" procedure) run if one of the subscriptions was renewed. This procedure has the following format:
PROCEDURE <Procedure name>(<Success> is boolean, <Product> is inAppProduct)
where:
  • <Success> is boolean:
    • True if the subscription was renewed,
    • False otherwise.
  • <Product> is an inAppProduct variable corresponding to the product for which the subscription renewal is checked.
Remarks

Principle and implementation

In iOS, you have the ability to create self-renewable subscriptions for the in-App purchases.
When this type of subscription expires, the subscription is automatically renewed by the AppStore. A new purchase transaction is automatically created and transmitted during the next application start. Therefore, this transaction must be supported by the application to take into account the subscription renewal.
inAppCheckSubscription must be called as soon as possible in the event "Initializing" of the project in order to process the subscription renewals. The procedure will be called as many times as the number of subscriptions to renew.
Component : wp240device.dll
Minimum version required
  • Version 23
Comments
Click [Add] to post a comment