- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-06-2019 11:08 PM
Hi team,
Please suggest me how to add print option in UI page, i have my HTMl code and I need to add button down of ui page once they click that button it should give us the windows option to print please suggest
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-07-2019 01:41 AM
Hi,
Can you try once with the below button in your html code. Just the below code any where and you don't need to define this function in your client script.
<button onclick="print()">Print
</button>
Note: Please mark this as correct or helpful if it helps!!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-06-2019 11:15 PM
Hi Radhi,
You can use the following script in UI page client script:
function printDiv() {
window.print();
}
in HTML script:
<button onclick="printDiv()">Print</button>
It'll work.
Thanks & Regards,
Prasanna Kumar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-06-2019 11:50 PM
Hi Prasanna,
I have kept the code in my ui page, i got print button but when i click it and did not get any response.
in similar way i tried with (onclick="window.print(); window.close();") but that is also not working!
Client script:
function printDiv(){
var cis = g_list.getChecked().toString();
}
HTML:
<button onclick="printDiv()">Print</button>
Thanks,
Radhika Chowdary B

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-07-2019 01:41 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-08-2019 01:27 AM
Worked like charm , Thanks.