You need to sign in to do that
Don't have an account?
Girbson Bijou 8
Print VF Page
Hi All,
I am using the following Script inside a VF Page to print the VF Page without preview it.
The page is rendered in the printer format but it Is also previewed in the backgroud (Screenshot below). i mean when i click on the button , The VF Page and the Printer page , the both are open. I do not want to preview the VF Page. If i could automatically send it to the printer when the button is clicked without any preview that would be awesome.
Here th starting of my page
I am using the following Script inside a VF Page to print the VF Page without preview it.
The page is rendered in the printer format but it Is also previewed in the backgroud (Screenshot below). i mean when i click on the button , The VF Page and the Printer page , the both are open. I do not want to preview the VF Page. If i could automatically send it to the printer when the button is clicked without any preview that would be awesome.
Here th starting of my page
<apex:page readOnly="false" action="{!updateDelivery}" showHeader="false" sidebar="false" applyHtmlTag="false" standardStylesheets="false" standardController="Delivery__c" extensions="DeliveryPageClass" applyBodyTag="false" > <head> <script type="test/javascript"> function printFunc(){ window.print(); } </script>
>> https://developer.salesforce.com/forums/?id=906F0000000BLD8IAO
As mentioned in the above link can you try checking if this helps: "Place an image on a printer on the top right hand corner (or where ever you think is suitable). Then on click of that image call a javascript function in that function execute this statement - window.print() - this will open the print window or depending on end user browser setting print the page.
"
Let me know if it helps you and close your query by marking it as solved so that it can help others in the future.
Thanks.
Here is my code, can you let me know where and how to insert it.