How to create a text file in unix server by running the java code in unix server?

2012-03-08T14:24:10

Can any one tell me how to create a text file in unix server through a java code?

I tried running the below code but it doesnt work.

BufferedWriter output = null;
File file = new File("D:\abc.txt);

Please help me out!!!

Copyright License:
Author:「user1256371」,Reproduced under the CC 4.0 BY-SA copyright license with link to original source & disclaimer.
Link to:https://stackoverflow.com/questions/9613697/how-to-create-a-text-file-in-unix-server-by-running-the-java-code-in-unix-server

About “How to create a text file in unix server by running the java code in unix server?” questions

Can any one tell me how to create a text file in unix server through a java code? I tried running the below code but it doesnt work. BufferedWriter output = null; File file = new File("D:\abc.txt...
I have written webdriver+TestNG scripts in windows using java. Now there is an upcoming requirement to run the same scripts in UNIX server without much of code modification. I have heard about runn...
I'm new in java. I have done an application and it contains a property file in which log path is configured. It is working fine in windows. This is the method for the same. File...
I have the following problem. I have a txt file named password.txt on a unix server. I have a java class on the same server. I have to read the contents of the password.txt using this Java class.
I have a Pro*C program which I run on Unix server say a but the input file required for this program is on other Unix server say b. Whenever I run I have to copy the file from server b to a. Is t...
How do I create a Java script that copies a file to a Unix Server? I need the process to be automated, as it's the need of my application that file should be automatically copied to the server with...
the below i have to do using a script which will be there on unix box server. I wanted to grep text(eg.Some_ID=123456) from log files present in log folder of my server. and want to c create and wr...
I want to write a couple of methods in a Java package, which would be deployed in a UNIX Server. As of now, my code was for Windows Server, for which I used the following code to zip Directory. pu...
I am trying to create a file in Unix server(netprobes run in this server) using ITRS Geneos active console. When I assign some alert to me or snooze any alert, a file must be created in unix server...
I have a server (Java) that is running on UNIX. I'm trying to develop some application that will "sense" if the state of the server has been changed and notify me by mail. I want to know how can ...

Copyright License:Reproduced under the CC 4.0 BY-SA copyright license with link to original source & disclaimer.