G
Guest
I'm trying to export a file with the current date and keep getting the
following error. "The Microsoft Jet database engine could not find the
object 'NPS100907.txt'. Make sure the object exists and that you spell its
name and the path name correctly." I could have swore this worked, but maybe
I already had a file with the aftorementioned name. Code below. Any help
would be greatly apprecieated.
Private Sub ExportFile_Click()
Dim stExpName As String
Dim stSpecs As String
Dim stExport As String
stExpName = "f:\RB_NPS\WolpoffExport\NPS" & Format(Date, "mmddyy") & ".txt"
stSpecs = "WolpoffExportSpecification"
stExport = "WolpoffExportFinal"
DoCmd.TransferText acExportDelim, stSpecs, stExport, stExpName
MsgBox ("Export Complete File Name is f:\RB_NPS\WolpoffExport\NPS" &
Format(Date, "mmddyy") & ".txt")
DoCmd.SetWarnings False
Dim stDateQry As String
stDateQry = "WolpoffExport_ChangeDate"
DoCmd.OpenQuery stDateQry, acViewNormal
DoCmd.SetWarnings True
End Sub
following error. "The Microsoft Jet database engine could not find the
object 'NPS100907.txt'. Make sure the object exists and that you spell its
name and the path name correctly." I could have swore this worked, but maybe
I already had a file with the aftorementioned name. Code below. Any help
would be greatly apprecieated.
Private Sub ExportFile_Click()
Dim stExpName As String
Dim stSpecs As String
Dim stExport As String
stExpName = "f:\RB_NPS\WolpoffExport\NPS" & Format(Date, "mmddyy") & ".txt"
stSpecs = "WolpoffExportSpecification"
stExport = "WolpoffExportFinal"
DoCmd.TransferText acExportDelim, stSpecs, stExport, stExpName
MsgBox ("Export Complete File Name is f:\RB_NPS\WolpoffExport\NPS" &
Format(Date, "mmddyy") & ".txt")
DoCmd.SetWarnings False
Dim stDateQry As String
stDateQry = "WolpoffExport_ChangeDate"
DoCmd.OpenQuery stDateQry, acViewNormal
DoCmd.SetWarnings True
End Sub