Click here to Skip to main content
15,881,898 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hey guys i am new to c++ and i`m trying to load .xml file it`s located at debug folder and "//Data/Filename.xml"
how i can read it using c++ ?

What I have tried:

i tried using ifstream fs("//Data/Filename.xml");

but the file is always not found even if i moved it to debug folder directly

its only reads file which in source folder :(

using VS 2017
Posted
Updated 9-Jan-18 20:46pm

1 solution

On Windows the path separator is '\' (instead of '/'). If the path is relative then it should be "Data\\Filename.xml".
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900