Solved

Barcode scanning

  • 23 March 2021
  • 9 replies
  • 274 views

Hi,

I've made a barcode scanner view where i scan a barcode and it inputs the text behind the barcode.
Is it possible that when i scan another barcode it automatically changes field “Barcode” with the new text? It needs to have the same effect as selecting the barcode text and scanning the new barcode. 
Is it something i can edit in Thinkwise or is it a seperate query that i need to write? 
 

Barcode after scanning. Scanning a new barcode doesn't have any effect on changing the Barcode field (i need to select the field and the value in it to make a change)

 

icon

Best answer by Mark Jongeling 14 April 2021, 08:43

View original

9 replies

Userlevel 7
Badge +23

Hi,

Since scanning a barcode is like copy-pasting in the barcode, you'll have to select all data of that field first. @cursor_to_col_id in the Default can help with that but maybe the following is more suited.

You can quickly select all data of a field (not HTML) by selecting its label as demonstrated here:

Quick select data by selecting the label

Does this answer your question?

@Mark Jongeling The @cursor_to_col_id is almost something that i want but i want it to jump back to barcode column every time i scan a barcode if that is possible? Now it jumps back to the next section when i scan the barcode.

Userlevel 7
Badge +23

That is not possible although it would be a great addition. Feel free to create an idea for this:wink:

Userlevel 1
Badge +1

@AmelRamulic  This sort of sound like a problem we faced. We had a field and every time the scanner filled the field it shifted to the next one. This happened since the scanner added an ‘Enter’ after each scan. We changed it in the scanner software to ‘Tab’. Then the GUI could handle it and we could use the @cursor_to_col_id to stay in the same barcode scan field en also empty the field so the user could scan the next barcode. Is this helpful? https://www.zebra.com/us/en/support-downloads/knowledge-articles/evm/add-a-tab-key-after-scanning-a-bar-code.html

@gariens I just changed the setting for tab key. Now if i set the @cursor_to_col_id it jumps to the next field “Order nr” below “Barcode” and it empties the “barcode” field. The thing i want to achieve is even when i’m at the “Rij” field or selecting a location and i scan a new barcode it needs to jump back to the “barcode” field and change it to the new barcode.

Userlevel 2
Badge +7

@Mark Jongeling 

You said "

Hi,

Since scanning a barcode is like copy-pasting in the barcode, you'll have to select all data of that field first. @cursor_to_col_id in the Default can help with that but maybe the following is more suited.

You can quickly select all data of a field (not HTML) by selecting its label as demonstrated here:

 

Is it known when this functionality will be supported in Universal GUI? Especially with mobile devices, it is very difficult to delete a field if an error has been made during scanning

Userlevel 7
Badge +23

@Mark Jongeling

You said "

Hi,

Since scanning a barcode is like copy-pasting in the barcode, you'll have to select all data of that field first. @cursor_to_col_id in the Default can help with that but maybe the following is more suited.

You can quickly select all data of a field (not HTML) by selecting its label as demonstrated here:

 

Is it known when this functionality will be supported in Universal GUI? Especially with mobile devices, it is very difficult to delete a field if an error has been made during scanning

Hi Marc,

I don't know if this functionality will be available in the Universal GUI but I can communicate it to the team.

Maybe you can have that Barcode input field accept twice the number of digits the barcode has. Let's say 12 digits. After the first scan, the field contains 12 digits, after the second scan, then it has 24 digits. Then with a Default procedure, you can select @field = right(@field, 12)  to select the 12 right-most digits. 

Userlevel 2
Badge +7

Hi Mark

 

That is a nice work-around. I’ll look into it!

Userlevel 7
Badge +23

Another way, maybe even a better way of implementing a Barcode input field is by using the following in the Default procedure:

if @cursor_from_col_id = '[column]'
begin
set @[column] = null
set @cursor_to_col_id = '[column]'
end

This way the Barcode data you input will be available in the Default procedure and can be transferred into different fields. If using your Barcode scanner results into it pasting data into the field and exiting the field (either by TAB or Enter input), then the code will force the Barcode field to be Null again and the focus will be brought back to the Barcode input field. 

This will allow you to scan indefinitely and will overwrite all data that was previously entered when configured in the Default procedure. I hope this helps and if it does, select it as Best answer.

Reply