sending output to printer?

How do I send my output to the printer as I do in the cmd window?
so I don't have to do a screen shot (ie. copy and paste output in a word doc.) and would save a lot of time.
I am using Microsoft Visual C++ 6.0,
F.S

Comments

  • : How do I send my output to the printer as I do in the cmd window?
    : so I don't have to do a screen shot (ie. copy and paste output in a word doc.) and would save a lot of time.
    : I am using Microsoft Visual C++ 6.0,
    : F.S
    :
    :


    the simplest solution using a console program is to use stdprn -- which is opened upon program startup just like stdin, stdout and stderr. If you are writing graphics to the screen, then writing the same graphics to a laser printer is pretty complex stuff -- MFC makes it a little easier, but not much. There are a couple c++ classes at www.codeproject.com that might help.

    Writing a word document is even more complex. M$ couldn't have made it more difficult. search msdn for "office automation". This is one case that VB excells over c++.

  • : : How do I send my output to the printer as I do in the cmd window?
    : : so I don't have to do a screen shot (ie. copy and paste output in a word doc.) and would save a lot of time.
    : : I am using Microsoft Visual C++ 6.0,
    : : F.S
    : :
    : :
    :
    :
    : the simplest solution using a console program is to use stdprn -- which is opened upon program startup just like stdin, stdout and stderr. If you are writing graphics to the screen, then writing the same graphics to a laser printer is pretty complex stuff -- MFC makes it a little easier, but not much. There are a couple c++ classes at www.codeproject.com that might help.
    :
    : Writing a word document is even more complex. M$ couldn't have made it more difficult. search msdn for "office automation". This is one case that VB excells over c++.
    :
    :

    No graphics, just standard output that is usually displayed in the dos command window. is what I want to send to the printer.


  • :
    : No graphics, just standard output that is usually displayed in the dos command window. is what I want to send to the printer.
    :
    :
    :

    then do this
    [code]
    FILE* fp = fopen("LPT1:","w");
    fprintf(fp,"
    Hello World
    ");
    fclose(fp);
    [/code]
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories