0
Answer

Printing a fixed length text file in different font and perserve alignment??

Ask a question

We have reports that come out of our accounting system that were generated by Cobol programs.. I need to be able to print the text files using C#..
I have gotten the printer to print the reports but in order to fit each line of the report (132 characters) on to 1 line of what is printed, I needed to change the font size..
The problem im having is when I change the font size, the alignment of the headers and data dont line up anymore.. When I look at the report in Notepad, its perfect..
Below is an example of what the report looks like in Notepad..
Run Date: Apr 26, 2010 - 11:26                  Company Name here                                     Page 1
         Customer #       Customer Name                   Address                 Zipcode
                 12345                     Testing          1234 street st                   90210
End of report
When I adjust the font, it looks like
Run Date: Apr 26, 2010 - 11:26                  Company Name here                                     Page 1
         Customer #       Customer Name                   Address                 Zipcode
              12345               Testing         1234 street st             90210
End of report
What I use our unix system to print the text report, It turns out perfect.. The command thats used to print is "lp -s -c -n## -oc -olpi8 -dprintername reportname.txt" if that helps..
What can I do here?