Note: To be able to use the samples you must install novaPDF SDK
as samples work only with it. Download it here: nova PDF SDK.
Hello World VB sample is a simple Windows console application that prints one page with the "novaPDF says Hello World from VB" text to the novaPDF Printer. It demonstrates the basic use of the INovaPDFOptions interface. The printing job is made with calls to the global Printer object defined by VB. It generates a "HelloWorld.pdf" file and opens it in the default PDF viewer. Notice If you print an existing document using "ShellExecute()" function or you want to handle printing events, you should check the VB Converter sample instead. Source Code
' The main entry point for the application. ' create the NovaPdfOptions object ' initialize the NovaPdfOptions object pNova.GetActiveProfile2 activeProfile, bPublicProfile On Error GoTo ErrorHandler: ' Print a test page For Each myPrinter In Printers Printer.FontName = "Arial" Printer.Print "novaPDF says Hello World from VB" pNova.SetActiveProfile2 activeProfile, bPublicProfile pNova.DeleteProfile2 "Test VB", PROFILE_IS_PUBLIC Exit Sub ErrorHandler: Debug.Print Err.Number & ":" & Err.Description End Sub |
Add comment

