From Clomosy Docs

Revision as of 12:20, 16 March 2023 by ClomosyManager (talk | contribs) (Created page with "It allows the serial number detected by reading barcodes to be transmitted to the electronic environment. After this stage, the transmitted information (on the computer or terminal) is analyzed and the result is reflected, so data entry is performed much faster and more accurately. CallBarcodeReader(TComponent) <span style="color:blue"> TComponent</span> : The component name will be written. After the barcode is read to the component name you have written, it will wr...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

It allows the serial number detected by reading barcodes to be transmitted to the electronic environment. After this stage, the transmitted information (on the computer or terminal) is analyzed and the result is reflected, so data entry is performed much faster and more accurately.

 CallBarcodeReader(TComponent)

TComponent : The component name will be written. After the barcode is read to the component name you have written, it will write the barcode code to that component.


Example:
We also made an example of barcode reading in the AddNewEvent feature. There is no need for variable definition in the application for barcode. Now let's see on the example. Let's add a button and when this button is clicked, the barcode will be read and put into the label.

Var   
MyForm:TFrmClomosyBasisForm;
testButton: TclButton;
testLabel : TclLabel;
procedure ReadBarcode; begin MyForm.CallBarcodeReader(testLabel); end;
begin MyForm:=TFrmClomosyBasisForm.Create(self);
testButton:=MyForm.AddNewButton(MyForm,'testButton','Read Barcode'); testButton.TextSettings.Font.Size:=40; testButton.Align := alCenter; testButton.Height := 50; testButton.Width := 150; testButton.Margins.Bottom:=200;
testLabel:=MyForm.AddNewLabel(MyForm,'testLabel','Barcode Code'); testLabel.Align := AlTop; testLabel.Width := 100; testLabel.Height :=50; testLabel.Margins.Top:=200;
MyForm.AddNewEvent(testButton,tbeOnClick,'ReadBarcode');
MyForm.Run; end;

Output:
BarcodeReader.png


See Also