L
Lana
Hi all,
I have a "MAIN" form where i set filters. I choose a condition in a combo,
then press button to show results in other form.
On that other form i have a button to open report which is supposed to show
the same data filtered according to condition set on MAIN form.
But i somehow fail to address MAIN form. Instead of opening the report it
sais it cannot find field "Forms". What is wrong in my code?
If IsNull(Me!Forms!MAIN!Status1) Then
DoCmd.OpenReport stDocName, acPreview
Else
stLinkCriteria = "[PrStatus]=" & Me!Forms!MAIN!Status1.Column(1)
DoCmd.OpenReport stDocName, acPreview, , stLinkCriteria
End If
Thank you.
Lana
I have a "MAIN" form where i set filters. I choose a condition in a combo,
then press button to show results in other form.
On that other form i have a button to open report which is supposed to show
the same data filtered according to condition set on MAIN form.
But i somehow fail to address MAIN form. Instead of opening the report it
sais it cannot find field "Forms". What is wrong in my code?
If IsNull(Me!Forms!MAIN!Status1) Then
DoCmd.OpenReport stDocName, acPreview
Else
stLinkCriteria = "[PrStatus]=" & Me!Forms!MAIN!Status1.Column(1)
DoCmd.OpenReport stDocName, acPreview, , stLinkCriteria
End If
Thank you.
Lana