Originally Posted by
edihelp
I need help converting this psuedo-code into vb.net
Then the rest of the steps would be (in pseudo code),
- open text file, read off the first 4 lines - this is the header
- loop 1
- start new record, add header lines you read off
- set flags hasData to false, twentyDetected to false, PlusDetected to false, endOfFile to false
- loop 2
-read next line -> if end-of-file, then set endOfFile to true, exit loop 2
- if line starts with "13" and TwentyDetected and PlusDetected and hasData then exit loop 2
- add line to current record
- if line starts with "13" and not hasData then set hasData to true
- if 3rd character in the line is a "+" then set PlusDetected to true
- if line starts with "20" then set TwentyDetected to true
- end loop2
- if endOfFile and not HasData then exit loop1 (discard current record because it is empty)
- save current record
- if endOfFile then exit loop1
-end loop1
- you are done
I am still a little unsure about the incrementers of each loop.