0

On the page i show a pdf document in iframe and i try to print it directly. At end of my search, this situation is suitable for IE 11 for the reason security etc. but how can i do that? I don't know. please save me this situation :/

I use these DOM element and function

<button type="button" onclick="printDoc()" class="btn success">Print It</button>

<script type="text/javascript">  
                        function printDoc() {
                           $(document).ready(function () {
                         document.getElementById("myDiv").contentWindow.print({
                                    bUI: false, bSilent: true,
                                    bShrinkToFit: true
                                });
                           });
                       };
</script>
kemal akoğlu
  • 182
  • 13
  • Possible duplicate of [javascript print without print dialog box](http://stackoverflow.com/questions/4292373/javascript-print-without-print-dialog-box) – kemal akoğlu Dec 23 '16 at 07:09

1 Answers1

1

ActiveX control does not work on IE11 as Microsoft no longer allows ActiveX plugins to run in its browser space.However if you are having 54 bit operating system you can try by forcing IE to run in 32-bit mode by adding the registry key as given below -

change the registry entry here:

HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main\TabProcGrowth or HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\Main\TabProcGrowth

Set it to something greater than 0 and restart IE11

keerti
  • 455
  • 2
  • 13