Android Question How to get remaining time of battery in basic4android

Discussion in 'Android Questions' started by Ramezanpour2, Jun 2, 2015.

  1. Ramezanpour2

    Ramezanpour2 Member Licensed User

    I'm create an app to optimize battery and battery saver but have 2 problems

    1.How to get remaining time of battery in basic4android

    2.How to close app that running in background andget number of thisin basic4android
     
  2. Ramezanpour2

    Ramezanpour2 Member Licensed User

    @Erel pllease helllp
     
  3. lemonisdead

    lemonisdead Well-Known Member Licensed User

  4. JTmartins

    JTmartins Active Member Licensed User

    You can't "guess" the remaining battery time, as that depends on the user activity.

    A simple action from the user as increasing or decreasing screen bright or turning on or off WI-FI or data connection or even making a few calls, will be enough to increase or decrease the amount of remaining time.

    You can extrapolate and try to guess, after analising for a few minuts of device operation, but will never be precise, or even close to that, unless the user leaves the phone still and does not touch it.
     
  5. Ramezanpour2

    Ramezanpour2 Member Licensed User


    no dear i want a code for close the applications that running in backgruond
    you haven't idea for calculate remaining tim of battery ????
     
  6. Cableguy

    Cableguy Expert Licensed User

    We don't give away code, we try to help you to get YOUR CODE working.
    READ the begginers guide, do some (re)search on the forum about your questions, TRY to get it working by yourself, and then, only then, if you can't get it working, ask for help WITH YOUR CODE.
    Also, this is a community forum, apart from very specific B4A inner aspects questions, you should not direct your question to a single user!
     
    DonManfred and Peter Simpson like this.
Loading...