# AppSourceCop Error AS0026
The type and subtype of parameters cannot be modified in events and external procedures
## Description
The type and subtype of parameters cannot be modified in events and external procedures.
## Remarks
It's not allowed to change the type or subtype of parameters in public procedures as this will break dependent extensions which are calling them.
> NOTE
> This rule allows to convert Option type parameters into Enum type parameters.
## Code examples triggering the rule
### Example 1 - Modifying parameters type
Version 1.0 of the extension:
```al
codeunit 50100 MyCodeunit
{
    procedure MyProcedure(i: Integer)
    begin
    end;
}
```
Version 2.0 of the extension:
```al
codeunit 50100 MyCodeunit
{
    procedure MyProcedure(i: Boolean)
    begin
    end;
}
```
In version 2.0, the type of the parameter i has changed from Integer to Boolean. If a dependent extension calls this method, this will lead to a compilation error similar to `Argument 1: cannot convert from 'Integer' to 'Boolean' (AL0133)`.
### Example 2 - Modifying parameters subtype
Version 1.0 of the extension:
```al
codeunit 50100 MyCodeunit
{
    procedure MyProcedure(i: Record Customer)
    begin
    end;
}
```
Version 2.0 of the extension:
```al
codeunit 50100 MyCodeunit
{
    procedure MyProcedure(i: Record Vendor)
    begin
    end;
}
```
In version 2.0, the subtype of the parameter i has changed from a Customer record to a Vendor record. If a dependent extension calls this method, this will lead to a compilation error similar to `Argument 1: cannot convert from 'Record Vendor' to 'Record Customer' (AL0133)`.
## Related information
AppSourceCop Analyzer<appsourcecop>
Get Started with AL<../devenv-get-started>
Developing Extensions<../devenv-dev-overview>

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/analyzers/appsourcecop-as0026, 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/analyzers/appsourcecop-as0026/
