I want to receive notification when Mobile network connection is lost or 
received. Through following code, I can receive notification for Wi-Fi 
(Data) connection but not for Mobile (Voice) connection.

Menifest :

<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
    
    <application android:icon="@drawable/icon" 
android:label="@string/app_name">
        
        <receiver android:name=".notifier">
            <intent-filter>
                <action android:name="android.net.conn.CONNECTIVITY_CHANGE" 
/>
            </intent-filter>
        </receiver>        
        
    </application>    

Java :

public class notifier extends BroadcastReceiver {    
    @Override    
    public void onReceive(Context context, Intent intent) {   
        
        Toast toast = Toast.makeText(context, "Network Changed !!", 
Toast.LENGTH_LONG);
        toast.show();        
    }
}

Please tell me, how can I receive notification for Mobile Network (Voice).

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to