broadcast - why android.net.conn.CONNECTIVITY_CHANGE register in manifest don't work at first time? -


i want listen network status,i use broadcast , register in androidmanifest.xml。but can't receive broadcast after app start. test in samsung s3 , nexus 5 , xiaomi,that happen.i know register in manifest static mode,if register in app code(dynamic mode) that's ok,who can tell why,is android bug?

<receiver android:name="com.l555iu.receiver.myreceiver">         <intent-filter>             <action android:name="android.net.conn.connectivity_change"/>         </intent-filter>     </receiver> 

do add permision access_network_state?

add 1 on manifest

this working on nexus 5


Comments

Popular posts from this blog

c# - How to get the current UAC mode -

postgresql - Lazarus + Postgres: incomplete startup packet -

javascript - Ajax jqXHR.status==0 fix error -