<div dir="ltr"><div class="gmail_default" style="font-family:times new roman,serif">I would not try to recreate the form as such: it is possible, but not required and does not add benefit to the solution as such.<br></div><div class="gmail_default" style="font-family:times new roman,serif"><br></div><div class="gmail_default" style="font-family:times new roman,serif">What you can do is to use the PDF as a background and just put the text on the right places. I have done this a couple of times, see e.g. <a href="https://www.uweziegenhagen.de/?p=2162">https://www.uweziegenhagen.de/?p=2162</a> or <a href="https://www.uweziegenhagen.de/?p=2081(both">https://www.uweziegenhagen.de/?p=2081(both</a> in German)</div><div class="gmail_default" style="font-family:times new roman,serif"><br></div><div class="gmail_default" style="font-family:times new roman,serif">Uwe<br></div><div class="gmail_default" style="font-family:times new roman,serif"><br></div><div class="gmail_default" style="font-family:times new roman,serif"><br></div><div class="gmail_default" style="font-family:times new roman,serif"> <br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Am Mi., 3. Apr. 2024 um 18:24 Uhr schrieb Christopher W. Ryan via texhax <<a href="mailto:texhax@tug.org">texhax@tug.org</a>>:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">I dream of using R, Rmarkdown, knittr, and pdflatex to pull individual<br>
records from a database and generate a form like page 1 here:<br>
<br>
<a href="https://www.cigna.com/static/www-cigna-com/docs/form-cms1500.pdf" rel="noreferrer" target="_blank">https://www.cigna.com/static/www-cigna-com/docs/form-cms1500.pdf</a><br>
<br>
one pdf form per database record, with the form fields populated. Then I<br>
could print them, and mail the bills to patients' insurers.<br>
<br>
The contents of many of the fields will be static: all records in the<br>
database pertain to the same lab test, all are ordered by the same<br>
physician (me), and all tests are conducted in the same place.<br>
<br>
The R coding seems straightforward, but using pdflatex to reproduce this<br>
complex layout strikes me as daunting--even before trying! Opinions: is<br>
this a fool's errand? Should I not even try?<br>
<br>
Thanks.<br>
<br>
--Chris Ryan<br>
</blockquote></div><br clear="all"><br><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div>Dr. Uwe Ziegenhagen</div><div>0179-7476050<br><<a href="http://www.uweziegenhagen.de" target="_blank">http://www.uweziegenhagen.de</a>></div></div></div>