Q. What version of Smart Print Control should I use with my version of Visual Basic? A. If you have Visual Basic version 6, you should use SPrinter.ocx. If you have Visual Basic version 5, use SPrinter5.ocx. Both controls work exactly the same; the only difference is that each one of the controls has the appropriate references to the VB runtime libraries of your version of Visual Basic. Therefore, when you distribute your applications, you do not need to include different versions of the VB runtime libraries.
Q. Do I need to register Smart Print Control on my system before starting to use it? A. If you have downloaded Smart Print Control OCX file only (SPrinter.ocx or SPrinter5.ocx), then you need to register it manually on your system. If you have downloaded and run the setup package of the control, there is no need to register it because the setup utility registers the control on your system. To register the control manually, use the Windows Regsvr32 utility. From the Windows Start menu, click Run and type:
For the VB6 version of Smart Print Control:
For the VB5 version of Smart Print Control:
Where FolderName is the full pathname of the folder where SPrinter.ocx (or SPrinter5.ocx) is located.
Q. On what platforms can Smart Print Control be used? A.Smart Print Control can be used on all 32-bit Windows platforms.
Q. In what programming languages can Smart Print Control be used? A.Smart Print Control can be used in any programming language that support ActiveX controls such as Visual Basic, VBA, Delphi, Visual C++, etc.
Q. Are Smart Print Control run-times royalty-free? A. Yes. You do not need to re-pay us to distribute Smart Print Control with your application.
Q. What libraries do I need to include with my application so that Smart Print Control can work on the user system? A.Smart Print Control requires only the VB run-time libraries (either MSVBVM50.DLL or MSVBVM60.DLL, depending on which version of Smart Print Control you are using). When you distribute your VB application (setup package), these libraries are already included in the package. Therefore, you do not need to include any any additional libraries. However, if you use the control in a programming language other than VB, you need to include the VB runtime libraries in your setup package.
Q. How can I add Smart Print Control to my VB project? A. From the Project menu, click Components. The Components dialog (below) opens. Click the check box to the left of the Smart Print Control and click the Apply button. The Smart Print Control will be added to the VB IDE Toolbox (shows like a printer icon). Double-click on the control icon to insert it on the currently open form.
Q. Can I print a text file directly with Smart Print Control? A. Yes. Use the FileName property to specify the file and send it directly to the printer to print it using the PrintDoc method. See the AllDataFromFile property for details on the file format if you want to also retrieve and print the document title, header, and footer from the file.
Q. I have more than one printer connected to my PC. Can I specify which printer to use to print the document? A. Yes. Use the GetPrinters method to retrieve all printer names and then use the PrintDoc method and specify the printer name on which you want to print your document.
Q. Can I specify a title for my document from within my code and specify the document body to be retrieved from a text file? A. Yes. Supply the document title using the DocTitle property and use the FileName property to specify the file name from which the document body to be retrieved. In this case, you must also set the AllDataFromFile property to False so that Smart Print Control considers the file contents as the document body.
Q. Does Smart Print Control support printers with multiple paper bins? A. Yes. Use the PaperBin property to specify which paper bin to use when printing the document.
Q. Does Smart Print Control support different paper sizes? A. Yes. Use the PaperSize property to specify the paper size to use when printing the document.
Q. Can I print a document using portrait or landscape orientation? A. Yes. Use the PaperOrientation property to specify the paper orientation.
Q. Can I specify a different line spacing when printing a document with Smart Print Control? A. Yes. Use the LineSpacing property to specify the line spacing to use when printing the document.
Q. Is it possible to specify the print quality when printing a document? A. Yes. Use the PrintQuality property to specify the print quality.
Q. Is it possible to specify the number of copies to print? A. Yes. Use the Copies property to specify how many copies to print.
Q. Can I specify different margins (left, right, top, bottom) when printing a document with Smart Print Control? A. Yes. Use the MarginLeft, MarginRight, MarginTop, and MarginBottom properties to specify each of the margins separately.
Q. Does Smart Print Control support printing graphics with the document text? A. No. This version of Smart Print Control does not support printing graphics. This feature however will be available in a next version of the control.
Q. Is it possible to know when the document has been sent to the printer spooler? A. Yes. Use the PrintComplete event. This event triggers when the entire document data has been sent by the control to the printer spooler.
Q. Can I specify different font face, size, character set, effects (bold, italic, underline, etc.) for each one of the document title, body, header and footer separately? A. Yes. Use the DocTitleFont, DocTextFont, DocHeaderFont and DocFooterFont properties to specify each of these properties separately.
Q. Do I need to insert Smart Print Control on every form in my application in order to print from each from? A. No. You can just put the control on one form (e.g. on your MDI parent form or on a hidden form) and use it to print from any other form.
Q. Would Smart Print Control understands that my file is actually an RTF file when I use the FileName property to print my file? A.Smart Print Control will always assume that the file is a text file unless its extension is '.rtf'. When the extension is '.rtf', Smart Print Control will process it as an RTF file. The extension is case insensitive. See also PrintRTFFile method.