Hi Hemali,
To generate a QR code you can use the "QR Code Generator" widget and print the specific detail you have to write a javascript action for it:
Like:
function printPage() {
window.print();
}
document.getElementById("printButton").addEventListener("click", printPage);