B
Bruno Frisque
Hi,
I have a report containing a subreport.
The main report is filtered by code and I'd like to filter the sub report
(containing many records) as well.
With the code below : error message : the settings is not valid for this
property etc ...
Private Sub Report_Open(Cancel As Integer)
If CurrentProject.AllForms("ClientsActuels").IsLoaded = True Then
Debug.Print "at SubRpt open!!!: ClientsActuel IS loaded" & " with IDKey
" & Forms!clientsactuels!MyIdEventKey ' = ok !
Me.Filter = "ideventkey = " & Forms!clientsactuels!MyIdEventKey '<<< error
Syntax ??
Me.FilterOn = True
end if
Many thanks in advance to tell me what's wrong !
I have a report containing a subreport.
The main report is filtered by code and I'd like to filter the sub report
(containing many records) as well.
With the code below : error message : the settings is not valid for this
property etc ...
Private Sub Report_Open(Cancel As Integer)
If CurrentProject.AllForms("ClientsActuels").IsLoaded = True Then
Debug.Print "at SubRpt open!!!: ClientsActuel IS loaded" & " with IDKey
" & Forms!clientsactuels!MyIdEventKey ' = ok !
Me.Filter = "ideventkey = " & Forms!clientsactuels!MyIdEventKey '<<< error
Syntax ??
Me.FilterOn = True
end if
Many thanks in advance to tell me what's wrong !