WebBrowser1.ExecWB(6,-1) and XP service pack 2

G

Guest

To all,

I have the following javascript in a cold fusion web page. It would print
the page without the printer dialog box. But after installing XP service
pack 2, it now prompts for the printer dialog box. I have tried this on
several PCs without service pack 2 it works properly, but as soon as you
install service pack 2 it then brings up the printer dialog box instead of
printing automatically. Any help would be great!....


Thanks!!!

<!----------- 8/3/2004 pas - add printit function --------------------------->
<script language="javascript">
function PrintIt(numreqs)
{
var WebBrowser = '<OBJECT ID="WebBrowser1" WIDTH=0 HEIGHT=0
CLASSID="CLSID:8856F961-340A-11D0-A96B-00C04FD705A2"></OBJECT>';
document.body.insertAdjacentHTML('beforeEnd', WebBrowser);

if (numreqs ==1){
WebBrowser1.ExecWB(6, -1);
}

}
</script>
 
D

David H. Lipman

This is a WinXP News Group not a scripting News Group. Please find and appropriate
Web/Scripting News Group.

Dave



| To all,
|
| I have the following javascript in a cold fusion web page. It would print
| the page without the printer dialog box. But after installing XP service
| pack 2, it now prompts for the printer dialog box. I have tried this on
| several PCs without service pack 2 it works properly, but as soon as you
| install service pack 2 it then brings up the printer dialog box instead of
| printing automatically. Any help would be great!....
|
|
| Thanks!!!
|
| <!----------- 8/3/2004 pas - add printit function --------------------------->
| <script language="javascript">
| function PrintIt(numreqs)
| {
| var WebBrowser = '<OBJECT ID="WebBrowser1" WIDTH=0 HEIGHT=0
| CLASSID="CLSID:8856F961-340A-11D0-A96B-00C04FD705A2"></OBJECT>';
| document.body.insertAdjacentHTML('beforeEnd', WebBrowser);
|
| if (numreqs ==1){
| WebBrowser1.ExecWB(6, -1);
| }
|
| }
| </script>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top