Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
MSFlexGrid and ADO
Message
Information générale
Forum:
Visual Basic
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00412017
Message ID:
00412055
Vues:
18
this is an example of how i use MSFlexGrid to return my recordset during runtime

Private Sub paysumm()
dim rsPaySumm as New ADODB.Recordset, _
iRecCount as Integer

rsPaySumm.Open "paysumm", adoEmpFile ,adOpenKeySet, adLockOptimistic, adCmdTable

With grdPaySumm 'the msflexgrid
.FormatString = "^DATE FROM|^DATE TO|>EMPLOYEE|>EMPLOYER"
.Rows = rsPaySumm.RecordCount + 1
.ColWidth(0) = 1200
.ColWidth(1) = 1200
.ColWidth(2) = 1200
.ColWidth(3) = 1200

For iRecCount = 1 To rsPaySumm.RecordCount
.Row = iRecCount
.Col = 0
.Text = rsPaySumm.Fields("period1")
.Col = 1
.Text = rsPaySumm.Fields("period2")
.Col = 2
.Text = rsPaySumm.Fields("mc_ee")
.Col = 3
.Text = rsPaySumm.Fields("mc_er")
rsPaySumm.MoveNext
Next iRecCount

End With

rsPaySumm.Close

End Sub
**elinore**
---------------------
"The most powerful weapon on earth,
is the human soul on fire" - Ferdinand Foch
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform