when i run the following code i am getting a bad DLL calling convention can anyone help cause it was working now its not 
thanks
Jason
Code:
Call Report_filters(strrpt, Datewhere, dateto, datefrom, opt)
Public Sub Report_filters(strrpt As String, Datewhere As String, _
dateto As String, datefrom As String, rpttype As Integer)
Dim stwhere As String
Dim today As String
stwhere = ""
today = Format(Now(), "ddmmyy")
dateto = Format(dateto, "mm/dd/yyyy")
datefrom = Format(datefrom, "mm/dd/yyyy")
stwhere = stwhere & Datewhere & " Between #" & datefrom & "# And #" & dateto & "#"
Select Case rpttype
Case Is = 1
DoCmd.OpenReport strrpt, acViewPreview, , WhereCondition:=stwhere
DoCmd.RunCommand acCmdZoom100
DoCmd.Maximize
Case Is = 3
' Reports!rptACCOUNTRX.Filter = stwhere
' Reports!rptACCOUNTRX.FilterOn = True
DoCmd.OutputTo acOutputReport, strrpt, acFormatPDF, "C:\TFRS REPORTS\" & strrpt & today & ".PDF"
' Reports!rptACCOUNTRX.FilterOn = False
End Select
thanks
Jason