# No enter/click app \[barcode reader\]

**URL:** <https://www.ruby-forum.com/t/no-enter-click-app-barcode-reader/61208>\
**Category:** Rails\
**Created:** [May 21, 2006, 8:16pm UTC](https://www.ruby-forum.com/t/no-enter-click-app-barcode-reader/61208 "2006-05-21T20:16:37Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/71c47a/32.png) [@Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/u/Jorge_Mario_GSMazo)\
**Post date:** [May 21, 2006, 8:16pm UTC](https://www.ruby-forum.com/t/no-enter-click-app-barcode-reader/61208/1 "2006-05-21T20:16:37Z")

</div>

I there  
We are making an app using barcode readers and it would be great if we  
did not have to hit enter or click each time an product is scanned,  
does anuybody has eny idea about how to achive this?

Thanks in advance

---

<div class="post-metadata">

**Author:** ![Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/71c47a/32.png) [@Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/u/Jorge_Mario_GSMazo)\
**Post date:** [May 21, 2006, 8:35pm UTC](https://www.ruby-forum.com/t/no-enter-click-app-barcode-reader/61208/2 "2006-05-21T20:35:48Z")

</div>

I really don’t think you can do that inside Rails itself.  
But building the JS should be simple. You basically just have an  
onChange on the text input. And monitor the length of the text field.  
When it reaches the length of a barcode code you make it submit.  
I’ll be happy to give you an example if you are unsure on how to achieve  
that.

On 5/21/06, Jorge Mario G. Mazo [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> 

–

---

<div class="post-metadata">

**Author:** ![Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/71c47a/32.png) [@Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/u/Jorge_Mario_GSMazo)\
**Post date:** [May 22, 2006, 1:28am UTC](https://www.ruby-forum.com/t/no-enter-click-app-barcode-reader/61208/3 "2006-05-22T01:28:33Z")

</div>

Also,  
Some barcode readers put carridge returns at the end of their  
transmission  
sequence. I used a barcode gun in a web application and it worked quite  
well. the only thing that was annoying was cursor focus but, again,  
javascript can _fix_ it.  
Nathan

---

<div class="post-metadata">

**Author:** ![Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/71c47a/32.png) [@Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/u/Jorge_Mario_GSMazo)\
**Post date:** [May 22, 2006, 3:34am UTC](https://www.ruby-forum.com/t/no-enter-click-app-barcode-reader/61208/4 "2006-05-22T03:34:48Z")

</div>

Jorge Mario G. Mazo wrote:

> I there  
> We are making an app using barcode readers and it would be great if we  
> did not have to hit enter or click each time an product is scanned,  
> does anuybody has eny idea about how to achive this?
> 
> Thanks in advance

Hi Jorge, we’re making a fulfillment app for cheap shipment in Europe.  
We’re planning to integrate barcode readers.  
Maybe we can share some ideas… Our website is [cebu.palmade.net](http://cebu.palmade.net) .

Thank you,  
Harm

---

<div class="post-metadata">

**Author:** ![Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/71c47a/32.png) [@Jorge\_Mario\_GSMazo](https://www.ruby-forum.com/u/Jorge_Mario_GSMazo)\
**Post date:** [May 22, 2006, 10:56pm UTC](https://www.ruby-forum.com/t/no-enter-click-app-barcode-reader/61208/5 "2006-05-22T22:56:24Z")

</div>

Hi there guys  
well our bar code guns “seem” to be the cheapeast and they dont add a  
return at the end…  
so it seems like the JS solution is the only thing we can do for now  
so Mr. Jon Gretar B. I would like to see that example,  
since I’ve been trying some things with JS, an example would be very  
apreciated

Thanks in advance

Jorge Mario G. Mazo
