I use OPENFILENAME to get dialog for file browsing and, as a result, I get in char szFileName[MAX_PATH] the filename that user is want to read from. I create ifstream and run open( szFileName) on the ifstream object .unfortunately the ifstream object is null
There could be the problem with "\" in the pathname?and I have to duplicate it?
If yes how?
Thank you

Provided I have no code to look at, if your programming in windows you need two "\" in the filename if you are defining the path explicitly. However, the way you are doing it you only need to type one backslash. Have you tried outputting szFileName to see what it contains??

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.