Mensaje
De
04/06/2008 04:58:39
 
 
a
04/06/2008 04:50:41
General information
Foro:
Visual FoxPro
Category:
Programación, sintáxis y comandos
Environment versions
Visual FoxPro:
VFP 8 SP1
Miscellaneous
ID de la conversación:
01321512
ID del mensaje:
01321518
Views:
20
Excellent!!!

Thank you

>Hi Chaim.
>
>To take the centre 10 characters you could do something like this -
>lcBarCode = Subs(lcEnteredCode, (Len(lcEnteredCode) - 10) / 2 + 1, 10)
>As for checking if the characters that you are throwing away are all not digits you could use -
>llNonDigits = (Len(lcEnteredCode) - 10 == Len(ChrTran(Stuff(lcEnteredCode, (Len(lcEnteredCode) - 10) / 2 + 1, 10, ""), "0123456789", "")))
>
>I hope that helps.
>
>Ian Simcock.
>
>
>>Hi
>>
>>I have to read Barcode.
>>I have to get 10 character with the following format 123456-789 (6 digits, dash +3 digits) .
>>My clients use with few bar readers that each one retrieve the results, but adding different characters for safe.
>>
>>for example:
>>*123456-789*
>>c123456-789c
>>*c123456-789c*
>>***123456-789***
>>123456-789
>>
>>I want to get always the 10 center characters.
>>In addition, I want to be sure that all the rest not digits (how to run isdigit function).
Thank you
Chaim
Previous
Responder
Mapa
Ver