private final Runnable mRunnable = new Runnable() {
public void run() {
TextView RX = (TextView)findViewById(R.id.RX);
TextView TX = (TextView)findViewById(R.id.TX);
long rxBytes = TrafficStats.getTotalRxBytes()- mStartRX;
RX.setText(Long.toString(rxBytes));
long txBytes = TrafficStats.getTotalTxBytes()- mStartTX;
TX.setText(Long.toString(txBytes));
mHandler.postDelayed(mRunnable, 1000);
}
}
collects data transferred(upload/download) by mobile internet on android device
-
21-06-2023 - |
Вопрос
How to collects data transferred(upload/download) by mobile internet
on android device from particular moment (date & time) and display it above status bar across the screen..
Решение
Другие советы
You can learn how to get transferred data on android from here How to obtain amount of transferred data through Wi-Fi from other applications?
and here's the notifications link,
http://developer.android.com/guide/topics/ui/notifiers/notifications.html
just a little google search.
Не связан с StackOverflow