Click here to Skip to main content
14,357,434 members
Rate this:
Please Sign up or sign in to vote.
See more:
Hi,

I am fairly new to visual C, have done some C / turbo C OOP in my early days. Have created a program using MFC APP Wizard in visual C++ 6, all functions seem to work, except I don't know how to print the program output from a list-box to a printer. Sorry if this is too simple a query for this forum.

MFC has created the following code, but I have no idea what code goes between the curly brackets.



Void CTensionAnalyserDLg::OnPrintbut()
{

//TODO: Add your control modification handler code here

}

Unfortunately I can't attach the program's dialogue box here, but happy to forward it to anyone that could help.

Cheers,
Rob

What I have tried:

Looked at a few samples but to no avail
Posted
Updated 17-Apr-19 22:37pm
Comments
Christian Graus 18-Apr-19 0:13am
   
It's 2019. VC6 was one of the worst implementations of c++. Why are you using it?
Member 14312188 22-May-19 19:49pm
   
Thanks Christian, VC6 is the platform I did my first VC development and it is still on my laptop. Will have to update to the latest version one of these days.
Christian Graus 22-May-19 19:57pm
   
You should, every version since has been a whole lot better :)

1 solution

Rate this:
Please Sign up or sign in to vote.

Solution 1

Printing is as easy as drawing. Read the Microsoft print documentation for an overview.

Here you find a primer print example and this more sophisticated example about Printing with MFC Made Easy.
   
Comments
Member 14312188 23-May-19 0:52am
   
Thanks Karstenk, will look into this.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100