My programme reads a line from a text file using
in_file_stream1.getline(read_record,255);
Each line in the file contains four fields, the numerical fields are right justified which means there will be a variable number of spaces between the fields. An example is
80-09V 7.00 470632.30 419554.80
Under certain circumstances the programme will detect an error and I want to display the line where the error occurred using cout in a console.
If I do this with
cout << read_record;
only the first part of the line is displayed - up to the first space. How can I get cout to display the full string?
Grateful for advice.