B4A Library Library AppStore. Easy access to app data from Google Play and the Apple iTunes

Discussion in 'Additional libraries, classes and official updates' started by MarcoRome, Jul 24, 2015.

  1. MarcoRome

    MarcoRome Expert Licensed User

    Hi all.

    This is simple library for easy access to app data from Google Play and the Apple iTunes

    Is very simple:

    AppStore
    Author:
    Devil-App
    Version: 1.02
    • appstore
      Methods:
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • Initialize (package_name As String, store As String, yourkey As String, Module As Object, EventName As String) As String

        Code:
        'Easy access to app data from Google Play and the Apple iTunes:
        'You have 2 parameters:
        'Initialize(package_name As String, store As String, yourkey As String, Me, "check_short")
        'package_name --> Play Store: "com.devil.app.antispy"  : AppStore: "6018"
        'store --> "google" if you want search this in Play Store or "apple" if you want search this in AppStore
        'Example:
        'Dim store As appstore
        'store.Initialize("com.devil.app.antispy", "google", "Fe5pwHzYKdmshHMC2Kq7NUIN0X3Ap1J54u4jsn62nFgdNmBJX9", Me, "check_value")
        '.....
        'Sub check_value(valore As typeLevel)
        'Log(valore.average)
        'Log(valore.count)
        'Log(valore.coverimage)
        'Log(valore.description)
        'Log(valore.developer)
        'Log(valore.fiveStar)
        'Log(valore.fourStar)
        'Log(valore.fulldescrition)
        'Log(valore.id)
        'Log(valore.Istalls)
        'Log(valore.lastUpdated)
        'Log(valore.maturityRating)
        'Log(valore.MinimunOsVersion)
        'Log(valore.oneStar)
        'Log(valore.price)
        '....
        'End Sub
        '******
        Code:
        Sub Activity_Create(FirstTime As Boolean)
            
        Activity.LoadLayout("1")
            
        Dim store As appstore
            
        store.Initialize("com.devil.app.antispy""google""Fe5pwHzYKdmshHMC2Kq7NUIN0X3Ap1J54u4jsn62nFgdNmBJX9", Me, "check_value")
           
        End Sub

        Sub check_value(valore As typeLevel)

            
        Dim carica_img As UniversalImageLoader
            carica_img.Initialize(
        "")
            carica_img.loadimg(valore.coverimage, ImageView1)
           
            Label1.Text = 
        "Average Rating: " & valore.average
            Label2.Text = 
        "Description: " & valore.description
            Label3.Text = 
        "Developer..: " & valore.developer
           

            
        Log(valore.count)
            
        Log(valore.fiveStar)
            
        Log(valore.fourStar)
            
        Log(valore.fulldescrition)
            
        Log(valore.id)
            
        Log(valore.Istalls)
            
        Log(valore.lastUpdated)
            
        Log(valore.maturityRating)
            
        Log(valore.MinimunOsVersion)
            
        Log(valore.oneStar)
            
        Log(valore.price)

        End Sub
        You have this result:

        2015-07-24 14.23.01.png

        Screenshot 2015-07-24 16.21.22.png

      • For get your Key HERE
        LIBRARY
        - Unzip the attached file ( AppStore1.02-Library.zip ) and copy AppStore.jar and AppStore.xml to the libraries folder
        - AppStore-Example1.02.zip is simple B4A ( for this example you must utilize also UniversalImageLoader By DonManfred ;) )
      • LAST UPDATE REL.1.02 - 25 March 2016
     

    Attached Files:

    Last edited: Mar 24, 2016
  2. Enrique Gonzalez R

    Enrique Gonzalez R Well-Known Member Licensed User

    Wow man this is awesome to promote your ownapps, you can even make ads like the ones for tapfortap.
     
  3. susu

    susu Well-Known Member Licensed User

    Thank you but how to get "yourkey" ?
     
  4. MarcoRome

    MarcoRome Expert Licensed User

    Right susu, sorry.
    For get your Key HERE
     
    Johan Schoeman and susu like this.
  5. cambopad

    cambopad Active Member Licensed User

    Wow! This is really cool! I now have an idea for an app using this lib, but how can I can the key? I click on your link to mashape....then ??
     
  6. MarcoRome

    MarcoRome Expert Licensed User


    For get your Key HERE
     
    cambopad likes this.
  7. cambopad

    cambopad Active Member Licensed User

    Thanks you! @MarcoRome Can you add the option to get screenshot? I can't find any method to get the screenshot of the app!
     
  8. MarcoRome

    MarcoRome Expert Licensed User

    I look at whether it is possible and let you know
     
    cambopad likes this.
  9. cambopad

    cambopad Active Member Licensed User

    Thanks will wait for this! :)
     
  10. MarcoRome

    MarcoRome Expert Licensed User

    Well... in attachment example. You can utilize this code ( look here ):

    Code:
    Dim filename As String = "screenshot.jpg"
      
    Dim Obj1, Obj2 As Reflector
      
    Dim bmp As Bitmap
      
    Dim c As Canvas
      Obj1.target = Obj1.GetActivityBA
      Obj1.target = WebView1
      bmp.InitializeMutable(
    Activity.Width,WebView1.Height)
      c.Initialize2(bmp)
      
    DoEvents
      
    Dim args(1As Object
      
    Dim types(1As String
      Obj2.target = c
      Obj2.target = Obj2.GetField(
    "canvas")
      args(
    0) = Obj2.target
      types(
    0) = "android.graphics.Canvas"
      Obj1.RunMethod4(
    "draw", args, types)
      
    DoEvents
      
    Dim out As OutputStream
      out = 
    File.OpenOutput(File.DirRootExternal , filename, False)
      bmp.WriteToStream(out, 
    100"JPEG")
      out.Close
    This is example


    2015-07-28 17.51.14.png

    and this is result in Jpeg:

    2015-07-28 17.51.27.jpg
     

    Attached Files:

    Johan Schoeman and cambopad like this.
  11. cambopad

    cambopad Active Member Licensed User

    Wow! Thanks you very much for your fast response! I really appreciate your kindness!But I think you misunderstood me! I think I confused you! Sorry!

    But I mean the screenshot data of the app on Playstore. For example, if you publish the app to Playstore, you will need App Icon, App screenshots,...
    So I want to ask whether we can fetch the screenshot of the app we specified from Playstore.

    Please take a look at the picture below:

    app_screenshot.png
     
  12. MarcoRome

    MarcoRome Expert Licensed User

    Ok Now understand... I look at whether it is possible and let you know
     
    cambopad likes this.
  13. cambopad

    cambopad Active Member Licensed User

    Really appreciate your work!
     
  14. MarcoRome

    MarcoRome Expert Licensed User


    Look HERE for new library AppStorePlus
    Comment 25/03/2016
    ( Dont work AppStorePlus because the service is delete, so i update this library look post #1 )
     
    Last edited: Mar 24, 2016
    cambopad likes this.
Loading...