# 502 - (Inventory) Barcode Validation

> Syslog 4.0 documentation · https://doc.sysdevmobile.com/syslog/extensibility/inventory/502-inventory-barcode-validation
>
> Função 502 do inventário: ações EXT_0502 Before, Replace e After na validação do código de barras, com parâmetros de lote, número de série e localização.

502 - (Inventory) Barcode Validation

| **Event**                                              | **Extension action set** | **Description**                                 |
| ------------------------------------------------------ | ------------------------ | ----------------------------------------------- |
| [Before ](https://doc.sysdevmobile.com/syslog/extensibility/inventory/502-inventory-barcode-validation.md#before)  | EXT\_0502\_1\_Before     | Will be executed before barcode validation;     |
| [Replace](https://doc.sysdevmobile.com/syslog/extensibility/inventory/502-inventory-barcode-validation.md#replace) | EXT\_0502\_2\_Replace    | Will be executed to replace barcode validation; |
| [After](https://doc.sysdevmobile.com/syslog/extensibility/inventory/502-inventory-barcode-validation.md#after)     | EXT\_0502\_3\_After      | Will be executed after barcode validation;      |

### Before

_Input Parameters_

* inFilterCabDoc – Unique key of the document;
* inBarcode – Barcode;
* inLocation
* inInventoryType - A - Assistida / C - Cega

_Output Parameters_

* outContinue – Return code:
  * 1 - Continue Validation
  * 0 – Cancel
* outRef

### Replace

_Input Parameters_

* inStamp
* inBarcode
* inWarehouse
* inAutoMode
* inLocation
* inInventoryType - A - Assistida / C - Cega

_Output Parameters_

* outContinue – Return code:
  * 0- Cancel
  * 1 - Done - Barcode inserted into the database, refresh list of articles to pick
  * 2 - Continue - Normal behavior
* outLastRef
* outLastDescription
* outLastQuantity
* outLastSerialNumber
* outLastLot
* outLastExpirationDate
* outLastLocation
* outUseLots - 0 - Don't use / 1 - Use
* outUseSerialNumbers - 0 - Don't use / 1 - Use

### After

_Input Parameters_

* inStamp
* inLocation
* inBarcode – Barcode;
* inInventoryType - A - Assistida / C - Cega
