invalid const char and char  to binary operator+
hi to all!
i'm posting for the first time here and also i'm new to c++! So,excuse me a priori. I'm trying to open a file with ifstream like this:
where 'event' is an inotify_event struct and 'name' is defined as char name; in this struct.
but i get : "error: invalid operands of types ‘const char ’ and ‘char ’ to binary ‘operator+’".
Tried to cast event->name by:
but nothing went right.
std::ifstream file("/home/alex/Desktop/csvDumps/"+(const char)event->name);
This code is in a while(1) loop and every time the name of the file to be opened changes. Any other idea for opening the file with an input variable like the one before is accepted!!
thanks in advance!!