Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Text box should accept value only by barcode scanner.
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00692776
Message ID:
00693173
Vues:
26
Zaheer,

I had basically the same problem and this is how I solved it.

I added the following code to the Valid event of the Textbox:

LOCAL lcBarCode

lcBarCode = ALLT(UPPER(This.Value))
This.Value = SPACE(0)

IF NOT EMPTY(lcBarCode)

IF LEN(lcBarCode) == 28 .AND. ;
SUBSTR(lcBarCode, 11 , 1) == "&"

Thisform.RetreiveReleases(lcBarCode)

ELSE

RETURN 0

ENDIF

ENDIF

NOTE: I added a special character "&" right in the middle of my barcode. Also, I don't suggest to configure your barcode with any special characters except with CR at the end. Trust me, that is a pain to maintain.

Alex.-
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform