Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Duplicate numbers
Message
 
À
16/03/2010 15:27:43
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 8 SP1
Divers
Thread ID:
01454921
Message ID:
01454928
Vues:
54
Shafid,

You can use a record lock to insure the barcode number is not duplicated. Example code is below (untested just use as an example).
LOCAL lnBarc
SELECT barcno   && table with barcode number
IF Barcno <= 0
   MESSAGEBOX("This computer is not setup with barcode numbers","")
   RETURN
ENDIF 	
DO WHILE NOT RLOCK()
ENDDO
lnBarc = Barcno.Barcno  
REPLACE Barcno WITH Barcno+1  &&increase by one
UNLOCK
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform