Private Sub Button1_Click
Log(IsFromGooglePlay)
End Sub
Private Sub IsFromGooglePlay As Boolean
Dim installer As String = GetInstallerPackager
Dim packages As List = Array("com.android.vending", "com.google.android.feedback")
Return packages.IndexOf(installer) > -1
End Sub
Private Sub GetInstallerPackager As String
Dim ctxt As JavaObject
ctxt.InitializeContext
Dim installer As JavaObject = ctxt.RunMethodJO("getPackageManager", Null).RunMethod("getInstallerPackageName", Array(Application.PackageName))
If installer.IsInitialized = False Then Return "" Else Return installer.As(String) 'ignore
End Sub