[Gambas-user] Example for download and print in gb.web/gb.web.form

T Lee Davidson t.lee.davidson at gmail.com
Fri Apr 17 19:23:53 CEST 2020


On 4/17/20 12:56 AM, Safiur Rahman wrote:
> Hi
> Can you please provide an example in gb.web/gb.web.form so that I can
> convert a HTML file into PDF and download it or send to printer.
> 

Perhaps the following would work for you. In a WebForm class:
Public Sub WebButton1_Click()

   Me.Exec("window.print()")

End

It does not convert the HTML into a PDF, but it allows the user the choice of printing to a printer or printing to a file (PDF).


-- 
Lee


More information about the User mailing list