Embedding a PDF into a dynamic page

Quick Summary: I am trying to embed a PDF (that exists as a link within a dataset) into an iFrame on my dynamic pages.

Detailed explanation: I have a dataset called “Datasheets”. Each item has a column called “PDF” which contains a secure link to the PDF file location on google drive.

Every row of the dataset has a different PDF link.

I want to embed the respective PDF into dynamic pages so that each dynamic page includes a visual of the document.

Statically, it works well if I place the link to the PDF within an iFrame, as seen in the image below.
The problem is that I don’t know how to do this dynamically by referencing the “PDF” column in the “Datasheets” dataset, and placing it within the iFrame.

I’ve looked around a lot online but have yet to find a good solution.

This will only work on a premium account that’s connected to your own domain (and might not work with a free wixsite.com domain):

$w.onReady(() => {
$w('#dynamicDataset').onReady(() => {
$w('#htmlComponenet1').src = $w('#dynamicDataset').getCurrentItem().pdf;
})
})