Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Controlsource-- grid??
Message
De
02/01/2000 09:56:22
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Controlsource-- grid??
Divers
Thread ID:
00311336
Message ID:
00311336
Vues:
66
i hv choose to use manual display the data from the table by adding column one by one( use coding not use grid builder)
but the sequence of the column display is not follow my coding, thta's mean the sequence is only the dtable column sequnce, not setting by me.
example
in table A some field field1, field2, field3 (in sequnce)

but i want to display the fields in sequnce: field2, field3, field1

my coding is:
* GRD_INFO IS AN ARRAY THAT GRD[x,1] CONTAIN THE HEADER, AND GRD_INFO[x,2] CONTAIN THE FIELD NAME
WITH THISFORM.GRID
.RECORDSOURCE = 'TABLE'
.COLUMNCOUNT = 3
FOR I = 1 TO 3
SELECT SODETAIL
.COLUMNS[I].FORECOLOR = RGB(0,0,0)
.COLUMNS[i].REMOVEOBJECT('Text1')
.COLUMNS[i].ADDOBJECT('Text1','Textbox')
.COLUMNS[i].HEADER1.CAPTION = GRD_INFO[I,1]
.COLUMNS[i].HEADER1.ALIGNMENT = 0
.COLUMNS[i].CONTROLSOURCE = GRD_INFO[I,2]
.COLUMNS[i].CURRENTCONTROL = 'Text1'
.COLUMNS[i].VISIBLE = .T.
.COLUMNS[i].SPARSE = .T.
ENDFOR
ENDWITH

but the grid display field sequnce is only just the database once setup sequence.
pls help!
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform