# InternalEvent attribute
> Version: _Available or changed with runtime version 4.0._
Specifies that the method is published as an internal event. It can only be subscribed to from within the same module.
## Applies to
 Method
## Syntax
```al
[InternalEvent(IncludeSender: Boolean [, Isolated: Boolean])]
```
### Arguments
IncludeSender
Type: ../methods-auto/boolean/boolean-data-type
Specifies that the firing instance of the object is available as a parameter to subscribers of that event.
*[Optional] Isolated*
Type: ../methods-auto/boolean/boolean-data-type
Specifies if event subscribers should be invoked in an isolated transaction.
## Snippet support
Typing the shortcut teventinternal will create the basic internal attribute syntax when using the AL Language extension for Microsoft Dynamics 365 Business Central in Visual Studio Code.
## Remarks
Learn more about isolated events in ../devenv-events-isolated.
## Example
Setting the attribute on a method. Each method must be marked with `[InternalEvent]`.
```al
codeunit 50131 MyInternalCodeunit
{
    Access = Internal;

    [InternalEvent(true)]
    procedure MyEvent()
    begin

    end;
}

codeunit 50132 MySubscriber
{
    [EventSubscriber(ObjectType::Codeunit, 50131, 'MyEvent', '', false, false)]
    procedure MySubscriber(sender: Codeunit MyInternalCodeunit)
    begin

    end;
}

```
## Related information
AL Method Reference<../methods-auto/library>
../devenv-events-in-al
../devenv-publishing-events
../devenv-raising-events
../devenv-subscribing-to-events
../devenv-events-isolated
devenv-method-attributes

Copyright (c) Microsoft Corporation. CC BY 4.0, https://creativecommons.org/licenses/by/4.0/; code samples MIT. From https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/attributes/devenv-internalevent-attribute, MicrosoftDocs/dynamics365smb-devitpro-pb at 828b6ee (2026-11-19). Changed: includes filled in, links to this site, and for agents shortened without dropping a fact. https://jonas-paprotka.de/docs/dev-itpro/developer/attributes/devenv-internalevent-attribute/
