How to create file path in Mac when creating a file? | Selenium Forum
M
Posted on 29/03/2016
In video 7, part 1, I'm using a Mac so when I give file path like this: File f = new File("Users\\tu\\Documents\\temp.txt");
It does not create tempt.txt file in the path i want, Users\\tu\\Documents
I get the file name to be this whole thing, Users\\tu\\Documents\\temp.txt under my java project Module7.

How to put the file in the folder I want?

M
Replied on 30/03/2016

http://superuser.com/questions/371513/how-to-tell-full-path-of-file-on-mac

http://stackoverflow.com/questions/5972026/path-to-file-on-a-mac-filenotfoundexception


M
Replied on 30/03/2016

I used this and it works. FileWriter w = new FileWriter("//Users//tu//Desktop//test1//temp.txt");