Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Random Number
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00585489
Message ID:
00586040
Views:
18
you can do this (this example from a form you can get the range from users then the code generates the numbers and writes to dbf )

Store thisform.text1.value to lncount
Store thisform.text2.value to lncount1

Rand(-1)
For ix = lncount to lncount1

lncount= Replicate("0", 6 - Len(TransForm(lncount))) + TransForm(lncount)
lncount1= Replicate("0", 6 - Len(TransForm(lncount1))) + TransForm(lncount1)

Select label
Insert into label (label) values ('!'+''+padl(ix,6,'0')+'!')

Endfor

HTH
Previous
Reply
Map
View

Click here to load this message in the networking platform