Re: Data Report urgent help
You are not setting the qty
you should also get rid of that on error resume next.
Re: Data Report urgent help
Re: Data Report urgent help
I did not see where you were setting the qty before but now I do. At a glance what is there looks like it should work but then again I use a different report tool and have never used the one built into VB.
I would think that you should be able to specify the number of copies when it is sent to the printer.
Re: Data Report urgent help
As DataMiser said, remove the On Error Resume Next and an error might come up and explain to you the reason why the loop would not work.
Re: Data Report urgent help
Why aren't you stepping the program through step by step in debug mode and looking at the change of variables ? (Its not a big program)
The error may be taking place in
Code:
Call printbarcode.PrintReport(False, rptRangeAllPages)
But you should see this when you step through the program ONE LINE AT A TIME
The variable qty is obviously set correctly and you can see this in debug mode - I suspect there is an error in the called routine which aborts the process somehow
Re: Data Report urgent help
This question was cross posted on VBForums where there has been a bit more info uncovered. As far as I can tell rather than printing multiple copies of the report what he was to do is print a variable number of barcode labels on the same page. Calling print in a loop will not solve this issue unless he uses a roll of labels on a label printer where each label counts as a page. To do this on a full size page the report will have to be designed to print a page full of labels with the same value or he will have to write code behind the report to populate the values. Otherwise would have to abandon the report and use the printer object setting current x and y values to print in the proper locations.
Re: Data Report urgent help
Just looking for a barcode generator, have you guys ever tried this? That would be so great if someone could shed some light on this!
Re: Data Report urgent help
Do you want to print and generate barcode label?I think using a barcode generator will make things easier.
Re: Data Report urgent help
That generator is C#
When generating barcodes there are a few things to consider. What type of barcode do you need, what kind of printer are you using.
In many cases a font will do the job, in other cases it is best to use the native printer language and in other cases may be best to use a 3rd party library or control