Hi,
I have never done this with Forms (always with Reports).
Anyway try something like this air code:
Sub PrintForms()
Dim db as database
Dim rs as Recordset
Dim strPath as String
Dim strFileName as String
Dim strMyForm as String
Dim strFullFileName as String
Set db = Currentdatabase
Set rs = db.OpenRecordset("tblFormNames")
Set strPath = "C:\"
rs.MoveFirst
Do while not rs.EOF
strMyForm = rs!FormName
'I don't know if Forms can be output as RTF but this works with a
report
strFullFileName = strPath & rs!FormName & ".RTF
DoCmd.OutputTo acOutputForm, frmMyForm, acFormatRTF, strFullPath,
False
rs.MoveNext
Loop
rs = Nothing
db = Nothing
End Sub
That will get your forms printed and into a directory. Emailing them
depends very much on the local email client but google the group for "send
Email" and you'll get a variety of solutions.
Kevin
<au********@gmail.comwrote in message
news:bb**********************************@m45g2000 hsb.googlegroups.com...
Hi,
I have an Access 97 database where the users loads the data (from
multiple sources) and generates forms (that looks like reports) at a
click of the button and the user saves the form as .xls and
distributes to other users via e-mail.
I need to automate the process of generating the forms, saving the
report and distributing to other users via e-mail
Can someone guide me in the right direction?
Thanks,
Audrey