function printTransactionDetails(htmlString)
'set objShell = CreateObject("Shell.Application")
'msgbox objShell
Const OLECMDID_SAVE = 3
Const OLECMDID_SAVEAS = 4
Const OLECMDID_PRINT = 6
Const OLECMDEXECOPT_DONTPROMPTUSER = 2
Const PRINT_WAITFORCOMPLETION = 2
MsgBox ("amogh0")
Set ie = CreateObject("InternetExplorer.Application")
'Set ie = new InternetExplorer
MsgBox ("amogh1")
'navigate to blank page so that the document object is available
ie.navigate "about:blank"
ie.visible=0
'msgbox ie.document.body.innerHTML
ie.document.body.style.margin = 20
ie.document.body.innerHTML=htmlString
'msgbox ie.document.body.innerHTML
ie.ExecWB OLECMDID_PRINT, OLECMDEXECOPT_DONTPROMPTUSER,PRINT_WAITFORCOMPLETION
'Quit IE
ie.quit
end function
上記のコードを含むJSPがあります..印刷に使用されます。CreateObject("InternertExplorer.Application") は、https://loclhost:8444/MyApp を使用するとエラーをスローしますが、https://10.192.51.xx:8444/MyApp を使用すると動作します