DoCmd.OutputTo

swoodworth

New member
Local time
Today, 05:28
Joined
Jul 12, 2007
Messages
1
Hello everyone.

I have a problem! I am trying to export to a .rtf (Rich Text Format). I want to be able to export the current record that i am working to this format. PLease help

Steve:o
 
Hello everyone.

I have a problem! I am trying to export to a .rtf (Rich Text Format). I want to be able to export the current record that i am working to this format. PLease help

Steve:o

Conceptually, create a query that will return the record that you are viewing on your form and then output a report with that query as the recordsource to rtf.
Place this code in the On Click event of a button on the form:
Private Sub button_Click()

DoCmd.OutputTo acReport, "nameofreport", "RichTextFormat(*.rtf)", "nameofoutputfile.rtf", False, "", 0

End Sub
Note: All of DoCmd. should be on the same line.
 

Users who are viewing this thread

Back
Top Bottom