I gotta void function that is taking two string files from the main function and inputting it into the main function....the line of code that keeps showing up as errors is: scanner1(name1, name2)
scanner2(name1, name2)
scanner3(name1, name2)
these are in the main function and the error message i keep getting is saying that the void functions cannot take 2 arguments. How do i allow this to...
User Profile
Collapse
-
Void Function problem
-
I took your advice and got this far, but now when i try to input name1 and name2 in the void function-functions, it shows up syntax error C2660 :"scanner1": does not take 2 arguments
...Code:#include <iostream> // For cin, cout, etc. #include <fstream> // For File input, output, etc. #include <iomanip> // For setprecision and setw #include <string> // For C++ string using namespace
-
Thanks that helped me through something I've been trying to figure out for 2 days now. Ive come to another bump in my code, but this one is a little bit different, I've got my void function now but I'm trying to make the name that I typed in for the file in the main function, I be able to call it into my void function.
...Code:#include <iostream> // For cin, cout, etc. #include <fstream> // For File input, output, etc.
Leave a comment:
-
Thanks that helped me through something I've been trying to figure out for 2 days now. Ive come to another bump in my code, but this one is a little bit different, I've got my void function now but I'm trying to make the name that I typed in for the file in the main function, I be able to call it into my void function.
#include <iostream> // For cin, cout, etc.
#include <fstream> // For File input, output, etc....Leave a comment:
-
File Input Problems
I am trying to design this code that will allow me to input a file, but it not be previously "hardwired" into the code, the user needs to input it, and I have almost figured it out, but i keep getting this error saying cannot convert from char to const char. If anyone can help me with this problem it would be appreciated.
#include <iostream> // For cin, cout, etc.
#include <fstream> // For File input,...
No activity results to display
Show More
Leave a comment: