Printing [modified]
-
Hi All Am developing an inventory package in C# 2005. in this customer needs printout of sales in preprinted stationary. right now am following it this way. On Clicking the grid and print button is selected am writing it to a TEXT file named SALESPRINT.TXT. AM HAVING PROBLEM FROM THIS PART, AM ABLE TO WRITE TO A TEXT FILE BUT THERE IS ALIGNMENT PROBLEMS. following is the format of the preprinted stationary. INV DATE xxxxxxxxxx INV NO xxxxxxxxxxxx PAGE NO xxxxx CUSOTMER ADDRESS1 xxxxxxxxxxxxxxxxx CUSOTMER ADDRESS2 xxxxxxxxxxxxxxxxx SL NO SHORT CODE ITEM NAME QTY RATE TOTAL xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 _______________________________________________________________________________ TOTAL xxxxx _______________________________________________________________________________ DISCOUNT xxxxx _______________________________________________________________________________ GT xxxxx so right now am using string.PadRight & string.PadLeft to specify the positions of contents in the text file. but am finding it difficult to do it. customer is using Dot matrix printer & preprinted continuous sheets for printing this. So to do this am i doing the right thing and am i on right track ???? Please guide to finish this, if anyone knows how t
-
Hi All Am developing an inventory package in C# 2005. in this customer needs printout of sales in preprinted stationary. right now am following it this way. On Clicking the grid and print button is selected am writing it to a TEXT file named SALESPRINT.TXT. AM HAVING PROBLEM FROM THIS PART, AM ABLE TO WRITE TO A TEXT FILE BUT THERE IS ALIGNMENT PROBLEMS. following is the format of the preprinted stationary. INV DATE xxxxxxxxxx INV NO xxxxxxxxxxxx PAGE NO xxxxx CUSOTMER ADDRESS1 xxxxxxxxxxxxxxxxx CUSOTMER ADDRESS2 xxxxxxxxxxxxxxxxx SL NO SHORT CODE ITEM NAME QTY RATE TOTAL xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 xx xxxxxx xxxxxxxxxxxxxxxxxxx 10 12.25 122.5 _______________________________________________________________________________ TOTAL xxxxx _______________________________________________________________________________ DISCOUNT xxxxx _______________________________________________________________________________ GT xxxxx so right now am using string.PadRight & string.PadLeft to specify the positions of contents in the text file. but am finding it difficult to do it. customer is using Dot matrix printer & preprinted continuous sheets for printing this. So to do this am i doing the right thing and am i on right track ???? Please guide to finish this, if anyone knows how t
Have you thinked to use crystal reports? Or create an HTML file instead of an txt? If is only to print purpose you can build an html
Visit my blog at http://dotnetforeveryone.blogspot.com/
-
Have you thinked to use crystal reports? Or create an HTML file instead of an txt? If is only to print purpose you can build an html
Visit my blog at http://dotnetforeveryone.blogspot.com/
But its making the print slow, right now am using this way. PrintTextWrite.WriteLine(PSLNO.PadRight(3) + " " + PKCODE.PadRight(14) + " " + PITEMNAME.PadRight(45) + " " + PQTY.PadLeft(40) + " " + PRT.PadRight(11) + " " + PTOT1.PadLeft(20)); but when size of PITEMNAME increases PQTY,PRATE,PTOT1 will go off the paper