Dark Bit Factory & Gravity

PROGRAMMING => Purebasic => Topic started by: speedhead on November 29, 2016

Title: handscanner USB
Post by: speedhead on November 29, 2016
Hi,

Has someone done any testing with a handscanner (USB) and how can purebasic can read input from the scanner.
I have done this in python but not in PB.

best regards
Speedhead of Mjau64 and Byterapers
Title: Re: handscanner USB
Post by: inc. on December 18, 2016
offtopic.
i remember using hand scanners in the early nineties. one of the first home scanners ever i think.

using today for what?

shouts.
Title: Re: handscanner USB
Post by: inc. on December 18, 2016
Has someone done any testing with a handscanner (USB) and how can purebasic can read input from the scanner.

btw...
i hope this answer your question :) see attachment
PureBasic wrapper and source
Title: Re: handscanner USB
Post by: speedhead on December 21, 2016
 :goodpost:

Thanks! i run Sample_ListAllDevices.pb

i get [01:54:56] [COMPILER] Line 89: Native types can't be used with pointers.
line 89 :

*vTable.i

 :-\
//Speed
Title: Re: handscanner USB
Post by: inc. on December 21, 2016
I guess you run the wrong PureBasic Version. Will test the code tomorrow.

Have you tested *vTable.l instead *vTable.i
Try long,  not integer.
Will test it later
Title: Re: handscanner USB
Post by: inc. on December 21, 2016
tested with purebasic version 5.30 = not working
tested with purebasic version 4.61 = working
Title: Re: handscanner USB
Post by: speedhead on December 23, 2016
Thanks, so i just bought new version of PB..i dont want to code java..just need listbox where text from textbox get..its a usb-scanner works like standard keyboard..so focus on textbox and press scanner button..the info then to a listbox and scan next same here info from scanner to listbox..vb6 i can do this fast..i just want to do things in pb

anyone textobx listbox a button example in pb...sort array sort listbox?

 :crutches:
//speed
Title: Re: handscanner USB
Post by: inc. on December 23, 2016
Which PB Version do you have installed?
Will correct the code for you.
Btw.
In your purebasic account you can download at Museum all older Version for free.
Title: Re: handscanner USB
Post by: inc. on December 23, 2016
changed:
working in PB5.30
should be fine in PB5.50 too, don't have this version installed

try Attachment