Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Filepath with foreign characters

Status
Not open for further replies.

sirugo

Programmer
Aug 1, 2000
162
SE
I'm having trouble with C++ trying to open a file on C: to which the path contains foreign characters.

I cannot change the name of the directory.

How do I get around it?
 
If i remember correctly, you can use double quotes "file_name" to have the program search entire HDD for the file_name without needing to include the path. This seems to be true when accessing header files that aren't necessarily in the compilers path.

Considering you're unable to cahnge the name of the directory, you could copy/move the file to a directory without foreign characters.

As far as the first paragraph, if incorrect, i have no issue being corrected.
 
I will not be able to move the file because the installation is already completed (100 computers on which the app will run).

In the first paragraph: you mean the compiler searches or the app itself will search each time it's executed?
 
The compiler will search for the program when it compiles the source. That is how i understood your first post. C++ has issues opening file on 'C'.
 
But I mean a file that should be read from and written to, a plain text file.
What if there are two files with the same name?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top