Report Form Formatting

stewart

Member
Joined
Jul 6, 2005
Messages
5
Programming Experience
1-3
Hi, I've been asked to make a glorified till as an assigment I'm doing for my course, and I'm stuck on the last bit. Basically I have a list of products all of differnt groups and I need to separate the groups so I can put a subtotal for each group, then a grand total at the end, see eample below.

100039 1 23 0 1 15 3.45 34.5 7.94
100128 3 14 0 1 16.5 2.31 39 5.46
100121 3 12 0 1 16.8 2.02 39 4.68
104170 6 0 570 2 10.9 62.13 28 159.60

The seventh digit is the code number, so I need to put a line of spaces between the 1 and 3 as well as the 3 and 6. The data was input from a text file using file open then putting it into an array, the writing it into a textbox with a For Next loop and the string split up using the substing method and vbTab, but this has led to a constant list, and I can't see a way of splitting the groups up so that I can put the finishing touches in. Can somebody help me please?
 
Try this

Well you can use database to do this task , if u are using some table then thats great.. use Crystal Reports to format data and put the fields where you like and have enough space between them.. and if u r using files then still u can print them using crystal reports.. it supports files too...
Good Luck
Bye
 
I've already looked into creating a table, but it would be a problem as it's a dynamic array I'm using and I don't know what size the table would have to be, plus I need to make the report presentable. I also looked into using a crystal report, but isn't it dependant on wether the other computer viewing the report having Crystal Report installed as well. And I think I'm being tested on the use of vbTab usage and other formatting techniques, using tables and crystal reports may be classed as cheating lol
 
I've sort of got arond the problem now, I ended up putting each product type into it's own array, but it's increased my code be *6 lol, and I'm one who likes to keep nice tidy code, so the question now is can it be possible to have an array of arrays so I can use a For.... Next loop to tidy my code up?
 
Damn, just noticed a flaw in my plan, because I'm using (differnt product type).Substring to split the strings up so I can print them in the textbox in the way I need to format them, it would mean messing around with them and I'm not so that it get's the right array string to manipulate, oh well my application works and I should get a pass which is all I'm after anyway. Thank you for your help :)
 
Back
Top