Chapter Contents

Previous

Next
GET_BARCODE

GET_BARCODE



Returns the value of the specified bar code


Syntax
Details
Example

Syntax

rc=IMGOP(task-id, 'GET_BARCODE', bar-code-type,
return-string<, x1, y1, x2, y2>);

bar-code-type
is a character string that contains one value from the following list:
'CODE39' code 39 bar codes
'CODE39X' extended code 39 bar codes
'CODE128' code 128 bar codes.

Type: Character

return-string
contains the returned value. Remember to make this variable long enough to hold the longest value that could be returned.

Type: Character

x1,y2
are the upper coordinates of the area in the image to search for the bar code. The default is 0,0.

x2,y2
are the lower coordinates of the area in the image to search for the bar code. The default is the width and height of the image. Note that the area specified for the bar-code location can be larger than the bar code. This area should be relatively free of things like other text.


Details

Given an image with a bar code, the GET_BARCODE command attempts to decode the bar code and then returns the value of the bar code. The bar code can be decoded only if it is clear in the image. The DPI resolution that is used when the image is scanned determines how clearly the bar code appears in the image. Below 200 DPI, recognition is very poor.


Example

Return the value of the bar code that is located in the 10,10,300,200 area of the image:

rc=imgop(taskid,'GET_BARCODE','CODE39',retstring,
        10,10,300,200);


Chapter Contents

Previous

Next

Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.