I had some doubts about fopen...
Can i perform the following?
fopen(\"%temp%\" , \"r\");
or do i need to use windows specific functions
On Windows you can use GetTempPath function that simply expands your %TEMP% env variable.
%TEMP%
Note, that starting from C++17 you can use std::filesystem::temp_directory_path