Solved

Printing pictures from HTML documents

Posted on 1998-09-24
2
145 Views
Last Modified: 2010-08-05
I'm developing a program which should be able to print HTML documents, including images. But I can't find any appropriate function in VB. I know of the Printer.PaintPicture method, but I can't print a picture from the system, like this:

sPictureToPrint = "c:\images\me.gif"
Printer.PaintPicture sPictureToPrint, 50, 50
0
Comment
Question by:liljegren
2 Comments
 

Author Comment

by:liljegren
ID: 1436427
Just want to mention that HTML is not enough in this case. I can't use the built-in web controls in VB5. Among other things I need to enable page breaking.
0
 
LVL 12

Accepted Solution

by:
mark2150 earned 100 total points
ID: 1436428
You need to load the picture into a control *first*, then use the PaintPicture method

Picture1.Picture = LoadPicture("PARTY.GIF")
Printer.PaintPicture Picture1.Picture, 50, 50
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question