Salut tout le monde j’ai le code suivant :
Il me génère cette erreur et je comprend pas ou est le problème !! aidez moi svp
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57 procedure TForm4.Button1Click(Sender: TObject); var Total :double ; j: Integer ; tableux : array[0..15]of string ; Mypage : TRavePage ; date1,date2 : string ; begin tableux[0]:='21-31'; tableux[1]:='22-31'; tableux[2]:='23-31'; tableux[3]:='21-33'; tableux[4]:='22-33'; tableux[5]:='23-33'; tableux[6]:='24-33'; tableux[7]:='21-34'; tableux[8]:='22-34'; tableux[9]:='23-34'; tableux[10]:='24-34'; tableux[11]:='25-34'; tableux[12]:='92-34'; tableux[13]:='94-34'; tableux[14]:='98-34'; tableux[15]:='21-35'; date1:='01-02-2012'; date2:='29-02-2012'; table1.Filtered:=True; Table1.Filter:='Date_demission>='+date1+'Date_demission<='+date2; table1.Refresh; table1.First; while not table1.EOF do for j:=0 to 15 do begin Total:=0; table1.Filter:='Imputation='+QuotedStr(tableux[j]); table1.Filtered:=True; table1.Refresh; //******** addition ******/// table1.First; while not table1.EOF do begin Total := Total + table1.FieldByName('Montant').AsFloat; table1.Next; end; With RvProject1.ProjMan do begin RvProject1.open; MyPage := FindRaveComponent('Report1.Page1',nil) AS TRavePage ; (FindRaveComponent('T'+ IntToStr(j) ,MyPage) AS TRaveText).Text := FloatToStr(Total); end; end; RvProject1.Execute; end;
Le projet Project1.exe a déclenché la classe d'exception EDatabaseError avec le message 'Expression filtre terminée incorrectement'.
Partager