I am looking up file names. The code is not complete here,
When I compile it there are no errors, but when I run it,
1. It does find the files and prints the fName4 value.
2. It does not print the fName7 value.
What am I doing wrong?
How do I get the value into fName7[i1]?
How do I get it back out?
The problem is not in finding the files,
the problem is in:
The end program will have the cout lines removed, these are here just to test what is happening.
When I cout << fName4, it displays the good names: enc_ref.000, etc.
When I cout << fName7[i1] all I get is the surrounding text.
I need an indexable array of valid file names to display (later in the program) for the user to make a choice. I also will be making changes within the base name itself as this program is further developed.
I do not understand the push_back thing and wonder how this is indexable?
I will have to do some study on this vector thing to see if it will do my job for me.
When I first learned programming (Fortran) more than 40 years ago, it was always considered important to have your code written simply so the poor guy who had to look at your code after you could easily understand it. I have always thought in simple terms since, that is one reason I used the inelegant method to increment the file extension.
I will clean up the code prior to final compilation.