7

I write a one POS system. I want to print on continuous paper but I don't figure out how I can accomplish this.

I use the .net (C#). I try with crystal report as well as System.drawing classes.

Any idea will be helpful for me...

AakashM
  • 62,551
  • 17
  • 151
  • 186
user404561
  • 71
  • 1
  • 3
  • You're going to have to clarify your question, I think. What do you mean that you want to print on continues paper? You want to print something over multiple sheets of paper? That should just naturally happen. Maybe show some code you have used so far. – LittleBobbyTables - Au Revoir Oct 31 '10 at 17:14
  • i think she means register tape.... – Muad'Dib Oct 31 '10 at 17:15
  • I think the word @user404561 was looking for is *continuous* i.e. on a roll of receipt paper. – Kevin Stricker Oct 31 '10 at 17:16
  • I want to print the invoices. I have a roll of paper in printer. the size (width is constant but the height) depend on the no. of items.. so its very.... – user404561 Oct 31 '10 at 17:17

2 Answers2

1

If you're using a C# PrintDocument to generate your print job, could you just initialize the paper size to what you need for header/footer then increment the PageHeight property before you draw a new line?

printdoc.DefaultPageSettings.PaperSize.Height += lineheight;
Kevin Stricker
  • 17,178
  • 5
  • 45
  • 71
0

I think you have three options: 1) You can precalculate the pagesize before printing 2) While you're printing the items check the Y position and compare it to the maximum Y position for items. If it's greater than maximum, print footer and ajust the Y positions for the un printed items. 3) Design an invisible box for each items and calculate how many of them fit in a page. Then you just need to divide the items in pages.

I hope my English is good enough.

Francisco Goldenstein
  • 13,299
  • 7
  • 58
  • 74