j'ai ce probleme , je doit parcourir les lignes et colonnes et je doit comparer chaque colonne si il est entre deux dates (DTpicker1 et DTpicker2) et afficher les données dans une etat crystal reports .
j'ai fai ce code la mais il m'affiche que 2 lignes :
With etatp
'Set rs = New ADODB.Recordset
rs.Open "Select * from Programme Order By coup_prg ASC;", devec_base
If Not rs.EOF Then
rs.MoveFirst
F2 = "{programme.coup_prg} In ['" & DTPicker3.Value & "','" & DTPicker4.Value & "']"
F2 = F2 & "or {programme.pré_prg} In ['" & DTPicker3.Value & "','" & DTPicker4.Value & "']"
F2 = F2 & " or {programme.mont_prg} In ['" & DTPicker3.Value & "','" & DTPicker4.Value & "']"
F2 = F2 & "or {programme.emba_prg} In ['" & DTPicker3.Value & "','" & DTPicker4.Value & "']"
F2 = F2 & "or {programme.livr_prg} In ['" & DTPicker3.Value & "','" & DTPicker4.Value & "'] "
F2 = F2 & "or {programme.mar_prg} In ['" & DTPicker3.Value & "','" & DTPicker4.Value & "']"
F2 = F2 & "or {programme.piquint_prg} In ['" & DTPicker3.Value & "','" & DTPicker4.Value & "']"
F2 = F2 & "or {programme.piquext_prg} In ['" & DTPicker3.Value & "','" & DTPicker4.Value & "']"
End If
rs.MoveNext
.ReplaceSelectionFormula F2
rs.Close
Set rs = Nothing
End With
Voila des example réel :
une etat générale
et celle la entre deux dates : 23/01/2000 et 11/11/2011
j'espere trouver une solution :/
Merci d'avance
A voir également:
Probleme Urgent Visual Basic 2006 et Crystal reports