Ms access print pdf vba code
Save your changes and test your button. Your report should now open in preview mode and automatically print. If as with an invoice you want the report to only print data for a specific customer you can replace the code in item 7 with the following:. Members Current visitors New profile posts Search profile posts. Log in Register. Search titles only. Search Advanced search…. New posts. Search forums. Log in. JavaScript is disabled.
For a better experience, please enable JavaScript in your browser before proceeding. I suspect the 2nd approach would be best.
THX for the code. I want every distinct pdf to have a specific name ex. The solution I came up with is DoCmd. Second question: I would like to store the pdf in a SQL-database. Anybody who has experience with this? Close acReport, reportName, acSaveNo. Your email address will not be published. Skip to main content. Any image, link, or discussion related to child pornography, child nudity, or other child abuse or exploitation. DefaultPrintername oPrinterSettings.
SetValue "Output", sFileName. SetValue "ConfirmOverwrite", "no". SetValue "ShowSettings", "never". PrintOut End Sub. Variables "AccountNo".
Was this reply helpful? Yes No. Sorry this didn't help. Thanks for your feedback. I guess this is a code for Word. But you showed me the right direction and i finally figured it out. But that's fine with me. Good code has it's price. BUT now i got another problem and maybe you had the same: My Report has orientation landscape.
If i print it to Pdf with Bullzip manually i get the correct result. If i do it via VB with Bullzip it's always portrait. Even if i set 'orientation' to 'landscape' the result is still the same ie wrong orientation Did you have the same problem and did you find a solution?
0コメント