Code:
Dim rs As DAO.Recordset
Dim sPath As String
Function ITAX()
sPath = "C:\temp\" ' just have the directory here
Set rs = CurrentDb.OpenRecordset("SAL")
Open sPath & "TAX.txt" For Output As #1
Do Until rs.EOF
EName = rs("name")
Edesg = rs("desg")
ecode = rs("ecode")
Print #1, ecode & Space(5) & EName & Space(5) & Edesg
rs.MoveNext
Loop
Close #1
rs.Close
Set rs = Nothing
End Function
Code:
0189 SMT BIMLA HEAD ASSTT 0190 SH PARTAP SINGH BIST HEAD ASSTT 018 SMT BIM HEAD ASSTT 019 SH TAP SINGH BIST HEAD ASSTT
Comment