История страницы
...
Read barcode from PDF Version 9 (Python)
Группа действий: Машинное зрение
Описание
Действие ищет в файле штрихкоды и считывает из них данные.
Иконка
Параметры
Входные параметры
Action group: Vision
...
Description
The action looks for barcodes in the file and reads data from them.
Icon
Parameters
Input parameters
File Path - The path to the file where you want to find barcodes and extract data from them. Supported formatsПуть к файлу Путь к файлу, в котором нужно найти штрихкоды и извлечь из них данные. Поддерживаемые форматы: jpg, jpeg, bmp, png, pdf.
Номер страницы Номер страницы файла, на которой нужно искать штрихкоды. Если поле не заполнено, поиск штрихкодов поиск штрихкодов будет осуществляться на всех страницах.
Тип штрихкода Тип штрихкода, который действие должно найти. Если выбрано «Определить автоматически», то будут найдены любые штрих коды в файле. Всплывающий список:
- Определить автоматически
EAN13
UPC-A
UPC-E
CODE 128
QR code
DATAMATRIX
DATAMATRIX (GS1)
Порядковый номер Порядковый номер найденного штрихкода, из которого действие должно вернуть данные . Если поле не заполнено, то действие вернет данные всех найденных штрихкодов. Нумерация начинается с 1.
Выходные параметры
Результат Коллекция, содержащая данные, которые были извлечены из штрихкодов. Один элемент коллекции – значение одного штрихкода.
Настройки
Page number - The page number of the file on which you want to search for barcodes
Barcode type - The type of barcode the action should find. If "Detect automatically" is selected, any barcode in the file will be found
Order - The sequence number of the found barcode from which the action should return data. If this field is not filled in, the action will return the data of all barcodes found. The numbering starts from 1
Output parameters
Result - A collection containing data that has been extracted from barcodes. One element of the collection is the value of one barcode.
Settings
Property | Description | Type | Filling example | Mandatory field |
---|---|---|---|---|
Parameters | ||||
File Path | The path to the file where you need to find barcodes and extract data from them. Supported formats |
Свойство
Описание
Тип
Пример заполнения
Обязательность заполнения поля
Параметры
Путь к файлу
: jpg, jpeg, bmp, png, pdf. | Robin.FilePath |
Yes |
Номер страницы
Page number | The number of the file page on which to search for barcodes. If the field is not filled in, the barcode search will be performed on all pages. | Robin.Numeric |
No |
Тип штрихкода
Тип штрихкода, который действие должно найти. Если выбрано «Определить автоматически», то будут найдены любые штрихкоды в файле.
Robin.String
Да
Barcode type | The type of barcode that the action should find. If «Detect automatically» is selected, any barcodes in the file will be found. Popup list:
| Robin.String | Yes | |
Order | The sequence number of the barcode found, from which the action should return data. If the field is not filled in, the action will return the data of all found barcodes. The numbering starts from |
Порядковый номер
1. | Robin.Numeric |
No |
Results |
---|
Результат
Result | A collection containing data that has been extracted from barcodes. One element of the collection is the value of one barcode. | Robin.Collection |
Особые условия использования
Если в файле есть штрихкод, который не прописан в алгоритм работы действия, то действие его проигнорирует. Неизвестный штрихкод не будет распознан, действие вернет пустую коллекцию.
Если штрихкоды повернуты под любым углом, то они будут распознаны.
Робот вернет пустую коллекцию, если не найдено ни одного штрихкода.
Робот вернет ошибку, если:
- в поле "Путь к файлу" подается недопустимый формат входного файла.
- неверно указан номер страницы (вне диапазона количества страниц в документе)
порядковый номер выходит за диапазон количества найденных кодов
Робот не вернет ошибку, если:
в файле неизвестный штрихкод= в файле нет штрихкода. Вернется пустая коллекция.
Пример использования
Задача
Существует изображение со штрихкодом, необходимо считать данные по шрихкоду.
Решение
Воспользоваться действием "Считать штрихкод из ПДФ".
Реализация
...
Результат
ОШИБКА!!!
Программный робот отработал успешно. Данные по шрихкоду распознаны.
Special conditions of use
- If there is a barcode in the file that is not specified in the action's algorithm, the action will ignore it. An unknown barcode will not be recognized, the action will return an empty collection.
- If the barcodes are rotated at any angle, they will be recognized.
- The robot will return an empty collection if no barcodes are found or an unknown barcode is in file.
- The barcode will not be recognized. The image has text, unnecessary information.
- The barcode will be recognized.
- Both barcodes will be recognized.
Example of use
Task
There is an image with a barcode, you need to read the barcode data.
Solution
Use the "Read barcode from PDF" action.
Implementation
- Move the "Read barcode from PDF" action to the workspace.
- Customize the parameters of the "Read barcode from PDF" action. Remember that the barcode will be read only if it belongs to the above barcode types from the dropdown list. In this case, it is type EAN13.
- Click on the "Start" button in the top panel.
Result
The program robot completed successfully. The barcode data has been recognized.
The result can be loaded into a collection by specifying a collection variable, or the result of this action can be input to another action that accepts the collection.
Thus, to display a result, you must either add an action that takes a collection as input, or specify a variable of type collection to be specified as a result of this action.