---
url: >-
  /flow/guide/scripting-reference/functions/host-specific/myob-exo/exonetcleanstockcode.md
---

# ExonetCleanStockcode

## Declaration

`function ExonetCleanStockcode(const S: string): String;`

### Example

```pascal
procedure OnMapEvent(var Value:Variant);
begin
Value := ExonetCleanStockcode('ABC:123'); //Value will be equal to ABC123
end;
```

## Description

Invalid characters will be stripped from S. This ensures the code is valid for use within MYOB Exo
