Android.Nfc.NfcAdapter.IsNdefPushEnabled Property
Return true if the NDEF Push (Android Beam) feature is enabled.

Syntax

[get: Android.Runtime.Register("isNdefPushEnabled", "()Z", "GetIsNdefPushEnabledHandler")]
public bool IsNdefPushEnabled { get; }

See Also

Android.Provider.Settings.ActionNfcsharingSettings

Value

Documentation for this section has not yet been entered.

Remarks

Return true if the NDEF Push (Android Beam) feature is enabled.

This function will return true only if both NFC is enabled, and the NDEF Push feature is enabled.

Note that if NFC is enabled but NDEF Push is disabled then this device can still receive NDEF messages, it just cannot send them.

Applications cannot directly toggle the NDEF Push feature, but they can request Settings UI allowing the user to toggle NDEF Push using startActivity(new Intent(Settings.ACTION_NFCSHARING_SETTINGS))

Example usage in an Activity that requires NDEF Push:

java Example

 protected void onResume() {
     super.onResume();
     if (!nfcAdapter.isEnabled()) {
         startActivity(new Intent(Settings.ACTION_NFC_SETTINGS));
     } else if (!nfcAdapter.isNdefPushEnabled()) {
         startActivity(new Intent(Settings.ACTION_NFCSHARING_SETTINGS));
     }
 }

[Android Documentation]

Requirements

Namespace: Android.Nfc
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0