Hi
I have the following file :
AH00010056445
AD20100428 0000250000000000
AD20100429 0000014521201000
AD20100501 0000000037600000
AD20100501 0000004892201000
AH00023603803
AD20100421 0000005000001000
AD20100512 0000002000001575
AD20100514 0000015000000800
AH00334945698
AD20100426 S0000039566700000
AD20100519 0000002892201350
AH denotes an account header (the number refers to a specific account) while AD refers to the detail of that specific AH. I need the code to loop from one instance of AH to the next while processing the AD in between.
So basically I would have three sets of data as follows :
AH AH AH
AD AD AD
AD AD AD
AD AD
I've tried various iterations of indexof, as well as foreach loops and arrays but I'm completely stumped.