Hi all,
i'm reading a file path from a serevr & going to read the contents in that file.
i created a ifstream object.but the problem is if the file path is c:\txt.txt,it doesn't read it as a file path.it reads \t as the tab.Is there any way to avoid this.In c# we can use @ sign.i thought of inserting one more dash manually.but it get complex if the file path contain many single dashes.
Highly appreciate all your great ideas.
Regards
Kaushalya
0
Newbie Poster
Recommended Answers
Jump to PostThe only way is to escape the backslash. C++ doesn't support verbatim strings like C#.
All 2 Replies
Reply to this topic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.