Add scan_barcode as custom field in custom doctype

how to create a scan_barcode like the one in Sales invoice i want to add it to my custom doctype

Please add the field.

Also check the scanner api and apply the logic according to the scenario.

really thanks i never expect name will make all this difference :heart: