Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Creating an order field
Message
De
07/01/2002 12:31:30
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00601526
Message ID:
00601551
Vues:
17
>Hi There,
>
>I need a way of sorting records in a flat file. My output is 4 records per page which are horizontal down the page, ie the first page contains the first four records, the second the next four. However I need to number each of the records so that when I have printed x sheets when the sheets are cut the top band contains the records in order, followed by the second band etc. Basically record numbers 1,5 and 9 should be numbered 1,2 and 3.... and so on down the bands. Each printed band should be able to be put on top of the band below with no break in the numeric sequence, and also the last page may contain any number of bands...
>
>I've tried using modulus with recno() and reccount() but still having problems getting a solution. Is there anybody out there who either can see a solution, or even decipher what I'm on about!!!!!

Simon,
You mean 1,5,9 should resolve to 1,2,3 pointing sheet numbers ?

floor((recno()-1)/4)+1
or :
ceiling(recno()/4)

Or individually to 1 as first rec on that sheet ?

(recno()-1)%4+1

Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform