NSEventFilter.EnableEvents
--------------------------

Enable some events which had been disabled before.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [NSEventFilter](component_NSEventFilter.md) | [2.9](newinversion29.md) | ✅ Yes | ❌ No | ❌ No | ❌ No | ❌ No |

MBS( "NSEventFilter.EnableEvents"; EventMask ) 

**MBS**( **"NSEventFilter.EnableEvents";** /\* Enable some events which had been disabled before. \*/  
**$EventMask**) /\* Which events to enable.e.g. 0 \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| EventMask | Which events to enable. | 0 |

### Result

Returns OK on success.

### Description

Enable some events which had been disabled before.  
Event filtering requires macOS 10.6 or newer.  
  
Possible values for the events:  
| NSLeftMouseDownMask | 2 |
|---|--:|
| NSLeftMouseUpMask | 4 |
| NSRightMouseDownMask | 8 |
| NSRightMouseUpMask | 16 |
| NSMouseMovedMask | 32 |
| NSLeftMouseDraggedMask | 64 |
| NSRightMouseDraggedMask | 128 |
| NSKeyDownMask | 1024 |
| NSKeyUpMask | 2048 |
| NSFlagsChangedMask | 4096 |
| NSScrollWheelMask | 4194304 |
| NSTabletPointMask | 8388608 |
| NSTabletProximityMask | 16777216 |
| NSOtherMouseDownMask | 33554432 |
| NSOtherMouseUpMask | 67108864 |
| NSOtherMouseDraggedMask | 134217728 |

You can add several mask values.  
### Examples

Enable scroll wheel events:

 MBS ( "[NSEventFilter.DisableEvents](NSEventFilterDisableEvents.md)"; 4194304 )  
Enable all right mouse events:

 MBS ( "[NSEventFilter.DisableEvents](NSEventFilterDisableEvents.md)"; 8+16+128 )  
### See also

- [NSEventFilter.DisableEvents](NSEventFilterDisableEvents.md)
- [NSEventFilter.EnableAllEvents](NSEventFilterEnableAllEvents.md)

### Blog Entries

- [MBS Filemaker Plugin, version 2.9pr9](https://www.mbsplugins.de/archive/2012-09-29/MBS_Filemaker_Plugin_version_2/monkeybreadsoftware_blog_filemaker)

This function checks for a license.

Created 18th August 2014 , last changed 10th August 2020

  
[NSEventFilter.EnableAllEvents](NSEventFilterEnableAllEvents.md) - [NetworkInterfaces.Count](NetworkInterfacesCount.md)

[HTML Version](NSEventFilterEnableEvents.shtml)