The easiest way to print the value of your string variable is to create
a report which will contain the value of your string variable and just
open the report programatically. The trick is to write the content of
the string to a table which would be the recordsource for the report.
Then open the report in ViewNormal mode. That will not bring up the
report it will just print the report. Say tbl1 is the recordsource
table for Report3 and only contains one field.
Private Sub cmdOpenReport3_Click()
DoCmd.RunSql "Insert Into tbl1 Select '" & str1 & "'"
DoCmd.OpenReport "Report3", acViewNormal, , , acWindowNormal
End Sub
Rich
*** Sent via Developersdex
http://www.developersdex.com ***