When you try to print messages in HTML format, you get an error message that says 'An error has occurred in the script on this page.' A URL is given as res://C:\WINDOWS\System32\shdoclc.dll/preview.dlg. Then it says 'Do you want to continue running scripts on this page'.
Solution:
Go to Start, Run and type
regsvr32 ole32.dll