I have an MS-Access form that tries to pass a filter to a report. Worked great with our old Office 03, now that we have Office 10, it does not work. Checked syntax and see no changes from old to new.
Has anyone else experienced this problem, and if so what is the fix?

Function Syntax:

Function inventoryrptfilter()
On Error GoTo inventoryrptfilter_Err
If Me.Filter = "" Then
DoCmd.OpenReport "INVENTORYreport1", acViewPreview, "", acNormal
Else
DoCmd.OpenReport "INVENTORYreport1", acViewPreview, , Me.Filter
End If

inventoryrptfilter_Exit:
Me.Filter = ""
Reports![Inventoryreport1].[Filter] = ""
Exit Function


inventoryrptfilter_Err:
MsgBox Error$
Resume inventoryrptfilter_Exit
End Function
Thanks