File 1 « File « Java Network Q&A

Home
Java Network Q&A
1.API
2.bluetooth
3.Client
4.connection
5.Cookie
6.Development
7.Email
8.File
9.ftp
10.http
11.HttpClient
12.https
13.ip
14.Network
15.OS
16.RMI
17.Security
18.Server
19.Socket
20.tcp
21.UDP
22.url
Java Network Q&A » File » File 1 

1. How can I have a batch file launched on a server from within Java?    stackoverflow.com

Is it possible to allow a client to click a button, and then trigger a batch file to run on the server? I am able to run the batch file ...

2. How do I play a wave file sent from server?    stackoverflow.com

I send a wave file using a client and server method. How could I play this file on the client once it's received? This is the server code used to send the wave ...

3. Best Way to Determine if *.doc File is RTF with Java or Coldfusion    stackoverflow.com

So I have about 4,000 word docs that I'm attempting to extract the text from and insert into a db table. This works swimmingly until the processor encounters a document ...

4. scripting in java - javascript from a server-side class file in Java 1.5    stackoverflow.com

I have three types of get requests that are delivered to a class file on web application from a mobile device. Because the mobile device provides no cookies, the log file ...

5. How to check if a static file in web server is updated or not?    stackoverflow.com

Any Java API in client side can check its modified date?

6. different configuration files for different server    stackoverflow.com

Hi How would you solved that? I have one application in which I have a few configuration files, I make war file and deploy it on the tomcat. But at the ...

7. How to get the corresponding file extension if the mimeType of the file is known    stackoverflow.com

When coding in java, How to get the corresponding file extension if the mimeType of the file is known?

8. Including Source in Archive File    stackoverflow.com

I was considering including the source code in my archive file (EAR, JAR, WAR) so we could see what the deployed application looks like. This will obviously make the archive much bigger. ...

9. How a war file gets deployed in any application server?    stackoverflow.com

I know that when a war file is created of my web application, i have to deploy it, that is if i am using JBoss i have to copy it to ...

10. FTPS - Signaling that a file has been downloaded    stackoverflow.com

I'm working on a Java-project where I need to download files via FTPS and wonder how/if there is a way to signal that the file has been downloaded at a later ...

11. RFC: What's a good approach to remotely edit very large binary files?    stackoverflow.com

I have a number of rather large binary files (fixed length records, the layout of which is described in another –textual– file). Data files can get as big as 6 GB. ...

12. A Problem while Retriving file from FTPS Server    stackoverflow.com

I am working in an application development. On that application i am performing files store, retrieve and delete operations. For identifying the files on server i am using an index(a hash ...

13. Creating small Java file server, space limitation    stackoverflow.com

So I am triyng to create small java server just for file storing with methods like Save(Key, Name, Data) ang Get(Key, Name). I want to limit my server file writing permissions ...

14. Problem in Overriding jetspeed.properties by modifying override.properties file in JetSpeed 2 Portal Server    stackoverflow.com

jetspeed.properties file contains a property psml.page.default = default-page.psml and i am overriding this porperty with psml.page.default = MyPage.psml in override.properties file but when i open http://localhost:8080 url, the default page(default-page.psml) get ...

15. How to run a batch file of server(which runs forever) and get the control back to the java program without closing that batch    stackoverflow.com

I have a java program:

Process proc = Runtime.getRuntime().exec("cmd /c callServer.bat");
int exitVal = proc.waitFor();
System.out.println("Process exitValue: " + exitVal);
Which is calling the batch file "callServer.bat":
@echo on
cd bin
call shutdown 2011
call server.bat
This batch file is ...

16. Stop the server using batch file?    stackoverflow.com

Can we stop servers using batch file? I am using Weblogic (v10) application server. I want to stop the server or kill the process using batch file. my application contains three Weblogic instances(Admin Server, ...

17. Manipulating BIND 9.x Configuration Files with Java    stackoverflow.com

I need to add/delete domain names to BIND 9.x DNS server. That means i need to read/write to zone files. How can I do this operation using Java? It is possible to ...

18. Any way to find out which NSF files are owned by the Domino Server    stackoverflow.com

Could someone please let me know whether there is any way how we could recognize a NSF file whether it belongs to the User or the Domino Server. For example, Domino maintains ...

19. Different file system JVM working in a same server    stackoverflow.com

In our 64bit server need to run 2 JVM, that is 32bit JVM and 64bit JVM parallel. We need to call on application from 64bit JVM and run in 32bit JVM. So ...

20. Generate a plaintext file from list of words on a webpage    stackoverflow.com

I am trying to generate a plain text file containing a list of words that is on a webpage. The problem is that the list is divided into multiple pages.

21. from server check for file on another server    stackoverflow.com

I have two server may be they will be at same network or not,while doing some work in jsp page at server 1 ,I want to check if file exist or ...

22. how to sort files on server in the client-server model?    stackoverflow.com

I am developing a client server model in which i need to send some TCP dump data to the server. The server will sort the data and will send it back ...

23. How to create an installation file server    stackoverflow.com

I have a server java project, which runs on glassfish. How does it put into the package and run on any machine and install it?

24. Set Java-web-start Trace file options from server-end    stackoverflow.com

Is there a way to set java web start trace file options (such as location and filename) through the JNLP or some other way from the server as opposed to modifying ...

25. What's a good sleep time to avoid java.net.SocketExeption: Unexpected end of file from server?    stackoverflow.com

Okay, so I'm using over 300 threads that use buffer readers to get information from over 300 sites at a reasonable speed. So basically, it spams this exception a whole bunch ...

26. Error when running batch file as a scheduled task , win server 2008    stackoverflow.com

I get a Exception in thread "main" Exception in thread "main" java.lang.NoClassDefFoundError error when I try to run a batch file as a scheduled task on windows server 2008. The batch ...

27. How to rename a file on server that is mounted locally?    stackoverflow.com

I try to rename a whole directory programmatically. The directory is on a server that is mounted on the local file system. I'm trying it to do like this:

public static void ...

28. java: find RSS file(s) of a website    stackoverflow.com

I am writing a java application; using Rome lib for reading RSS feeds of a RSS file of a website. I can read and manage feeds using Rome but ...

29. Fell into infinite loop while receiving file using datainputstream and bufferedinputstream    stackoverflow.com

I am trying to build a server program that receives file from client using DataInputStream and BufferedInputStream. Here's my code and it falls into infinite loop, I think it's because of not ...

30. java network-broken pipe and received file corrupted    stackoverflow.com

I am trying to write a server that accepts files and write it in certain directory using DataInputStream and BufferedInputStream. The server gets 'user name(string)' 'number of files(int)' 'file name(string)' 'size of ...

31. Rename files on Darwin server from java    stackoverflow.com

I have a requirement in which I need to connect to server which has Darwin Kernel and need to rename files in certain folders. The server has FTP turned on. The application ...

32. Include attachment in .ics file for a response to a meeting request    stackoverflow.com

I am using the following tag while creating my ics object;

Attach;FMTTYE= text/plain ;ENCODING =BASE64; VALUE =BINARY : (base 64 encoded text for a image)
But it seems server not able to parse ...

33. Deploy java file on a company server    stackoverflow.com

I have a java file written in Netbeans IDE on my local pc. I have to deploy this file on the company server. Basically, this file acts as a listener and it ...

34. get file out of server    bytes.com

Depends on what you mean by 'load'. Are you wanting to load and execute code from the server, within the context of the active document, or simply load an entirely new ...

35. compile a java file within solaris server    bytes.com

I have to modify a .java file in a project. But I dont have any editor to compile java. I use putty to connect server(Solaris). And using putty console I modify ...

36. creating new files in server    coderanch.com

37. Edit Server side word file using java --- vikas    coderanch.com

Hi, I would like to know if it is possible to edit a server side .doc file from the client location.Also If I save the word file on the client machine, then the server side .doc file should get updated. If this is possible please let me know the help url's for the same. Regards, Vikas

38. Unexpected end of file from server    coderanch.com

39. open a file located on server    coderanch.com

Hi I'm trying to open a file located on my server. My server's name is omni this works when i want to open a file located on my computer : Runtime.getRuntime().exec("cmd /c start c:"+File.separator+"sdiack"+File.separator+"java"+File.separator+"timesheetserver"+File.separator+"feuilledetemps.html");} this does not work when i try to open a file located on server omni : Runtime.getRuntime().exec("cmd /c start omni:"+File.separator+"test"+File.separator+"files"+File.separator+"dir1"+File.separator+"file1.html");} Please help! thanks

40. Unexpected end of file from server    coderanch.com

41. regarding file creation on server -very urgent    coderanch.com

hi all Im using apache tomcat 4.1 server how can i create a folder at server and copy the file in that folder if the client uploads the file. i have tested my code on my own system where client and server are on the same machine the code is String path= "c:\program files\apache tomcat 4.1\webapps\jetspeed\technologies"; //im creating the folders by ...

42. Getting file size server side with javascript    coderanch.com

I have a jsp which calls a java file that open a text file and reads in a line at a time and creates an array which is then used in the jsp. However when opening the file I want to check the size of it first and if its to large display a message to the user stating this. Any ...

43. Creating file in the web server    coderanch.com

Hello experts! Actually while executing: String s =config.getServletContext().getRealPath("/"); I got the string as: /home/cascanicacom/public_html/ Thats the root I suppose. But after getting the root path. Now I need to create a file "write.txt" and save it in the /home/cascanicacom/public_html/ folder. The code i used before was : File file = new File("write.txt"); Now please tell me where should I make the ...

44. Retrieving file at server side    coderanch.com

Hi, I am facing an interesting problem. Problem : We have an ejb component that sends mail messages to different clients. Now we have to insert the add attachment feature. Approach : For this purpose we must have the file content at server side. That can be done by using ftp or other protocol from the server side itself as we ...

45. Available space for file on server    coderanch.com

Hello A server accepts files from a client. The files could be any size. The client can communicate the file's size to the server before starting the transfer which is fine. What I am trying to achieve is to be able to respond to the client whether or not there is enough space on the server to store that file before ...

46. downloadindg file server    coderanch.com

48. creating new files in server    coderanch.com

50. generate a text file in another server ??    coderanch.com

the easiest solution would be to set up a server of some sorts ont he NT machine and have it accept files and store it on its file system independently of the web server. otherwise, I've never tried accessing network resources but - the NT system mustnt be set up with NTFS since the only linux driver for NTFS i know ...

51. Opening a File in the server    coderanch.com

53. down load file from server    coderanch.com

55. Accepting File Uploads to Server    coderanch.com

I'm using ServletFileUpload and parseRequest(req) to accept file uploads to the server. It seems to be the case that once you call parseRequest to get a List of file items, you can not call it again later. I would like to parse the request once to figure out what is being uploaded and then pass the request off to a handler ...

56. storing text files server side.    coderanch.com

Good morning, I have the following problem: I have created in my desktop a small servlet which has the capability of storing and retrieving text files from a local directory. Say that this directory is specified as a context parameter in the DD, like: C:/.../webapps/MyServletProject/WEB-INF/userData/users.txt My question is: how can I deploy this server side? Is there a general way to ...

57. Loading file from server into browser window    coderanch.com

Hello, I'm developing and jsp, with some struts, application and am required to keep a folder of image and pdf files outside the application context and on the server - ie c:\files\load. The files need to reside outside the application so that they are not wiped out when a new war file is deployed. I've done this many times for an ...

58. Printing server port number in java file    coderanch.com

Originally posted by naresh bv: I want to get the port number of a server dynamically. For ex: If I use tomcat server then I will get port number as 8080 If I use WebLogic then that will be 7001, so on.... How can i get that port number in normal java file. I could not get the questions properly. Well ...

59. How to store a file on server    coderanch.com

Hi All, Thanks a lot in advance. We will deploy the application on websphere server through URL which is at remote place by creating ear file. Now, I have on pdf file which is a fixed one and it wont be changed in future also and I am opening this pdf on click of a link. Due to this large pdf ...

61. Downloadinf a file from server    coderanch.com

What a browser does when a file of a certain type is sent to it by the server depends on the Content-Type HTTP header that's in the response. If Content-Type is set to "text/xml", then the browser will probably display it as an XML file. If the Content-Type is set to something that the browser doesn't recognise, then it will offer ...

62. store a file in the server    coderanch.com

Personally, I'd recommend against storing the files within the body of the web application. By doing so, you create complications with upgrades and redeployment. I've done setups like this many times and I store the files independently of the web app so that I can upgrade and redeploy the web app without worrying about clobbering the files, Access to the files ...

63. Store Files on a Server    coderanch.com

I am using the Tomcat 5.0.27 web container. I have always store things into the database. Now, I am told to store files (uploaded files) on the server. And, when clients want the files later on, clients can download them. Because I have not yet had this concept, I need help and explanation. 1. How to store files on a server? ...

64. Transfering Files On Server    coderanch.com

I need to move files from one directory to another (development folder to production). This is a Linux system. Someone was telling me it is not to difficult to run a shell script from Java. If this is the case I think it would be a pretty easy solution. Is there any other solutions people have used for this situation? Thanks, ...

65. Manipulating files on server    coderanch.com

Hi, I am using Apache commons API to connect to a server through FTP. I want to copy 1 file from one location of server to another. I am getting the contents of the file using the FTPClient.retrieveFile() function.But now when I want to write these contents to another file on a different location, I am getting error:- String destPath="/home/gunja/server/myFile.txt"; File ...

66. how to define other server's file in classpath    coderanch.com

Does anyone can explain to me how to define other server's file in classpath I have a batchfile to set classpath for all jar file. However, I need to set a specific .jar where is in other server like below e.g set JDBC_Home=\\QIBM\ProdData\HTTP\Public\jt400\lib\jt400.jar(i need to set this in CLASSPATH) set CLASSPATH=%CLASSPATH%;..\lib\vertex_tax.jar set CLASSPATH=%CLASSPATH%;..\lib\vertex_taxgis.jar set CLASSPATH=%CLASSPATH%;..\lib\vertex_util.jar set CLASSPATH=%CLASSPATH%;..\lib\xercesImpl.jar How do I set ...

67. Files processing on server    coderanch.com

We have a swing based application which gives an option to the user to browse and select an excel sheet from the local file system. This excel sheet will contain names of various files and their path on the local filesystem. This excel sheet I am reading using POI. Once the sheet is selected it'll be read using POI and all ...

68. Server-side starter application - file handling.    coderanch.com

Hi everyone, I've just arrived here from the Head Start book and thought I'd drop in for a while. Although I used to scratch a living from software development I'm new to OO concepts in general and Java in particular. I'm only halfway through the book and looking for an excuse to use Java. After some little warm-ups on my laptop, ...

69. how to include jpg file on server    coderanch.com

70. User Selection of File from Server    coderanch.com

71. how to overwrite a file in server    coderanch.com

Welcome to the JavaRanch, Jasmine! First, I remind everyone that a web server is not a file server (I do this a lot!). Meaning that a web client (browser) cannot itself write any file to the server. All it can do is upload a file and let the web application find something to do with the data. Which may or may ...

72. problem in deploying WAR files in server    coderanch.com

'www' is the default package provided by the web-hosting where i should put all my files. I tried putting my 'index.html' just inside the 'www'. And accessed it successfully with the url '...//mysitename.com/index.html' not '...//mysitename.com/www/index.html' (accessing it this way does not solve my problem). If i put my 'index.html' outside 'www' folder, server can't identify that. So it proves that 'www' ...

73. where to put .WAR files on server?    coderanch.com

Hi, I am able to do some simple servlets and run them on the localhost...but I want to deploy on a home server I have....I tried exporting the war file (I'm using eclipse) to /webapps/filename.war.... but I cant run the applcation from there... also, when I try to view the .WAR file I can't see it, either in the terminal or ...

74. Writing/Upload file to 2 servers    coderanch.com

We faced a similar problem. The first thing we did was hide all File I/O behind an interface that had 2 methods: save and load. It's important that none of your code accesses the filesystem directly because you want this kind of file replication to be handled consistently. The first implementation of this service will probably just do whatever you are ...

75. How to open File on server Using JCIFS or any other method    coderanch.com

I am having a problem , My server is in Linux and I have to open the file (Excel File) on clicking a button , Since Linux Server has password , I am unable to open without authenticating on to server ,I am able to open file on Windows Server which is not having the password. So I used JCIFS and ...

76. how to create a file on web server at runtime    coderanch.com

Hi Thanks for the responses.. @Maneesh i cannot use ServletContext#getRealPath as it is creating other problems for me. Also it requires a file as a parameter where as in my case the file has to be created and is not existing currently. @Bear Honsestly I would not like to keep the file in my web app folder but I am not ...

77. Copy/moving a file from one location to Server location.    coderanch.com

You could poll a known directory for the Excel files, and transfer them as they appear. There can be issues with synchronization though. For example, your process could see the Excel file and try to start transferring it before it has been fully created, or while its still being edited. One common trick is to write the file with a different ...

78. how to create a file on server.    coderanch.com

You are seeing full path to the file in that output message. If you're not seeing such file in you'r file explorer, perhaps it's hidden or somehow invisible to the user. Copy full path of that file, run notepad or other you'r text editor and click open -> paste copied path -> return key press.

79. how to check whether a file exits in a server or not ?    coderanch.com

suppose i m connected with the server (a client server thing ) can i check whether a file exit in a server or not but with file.exits() i guess it only works with current system so how to do this , i know there must be something in java for the same ?

80. Connecting to a file on a server    java-forums.org

can anyone inform me as to how i can connect a java application to a server on the same network so I can read a file. I can access the server from a clint computer by typing \\computername on the windows search box. The program resides on this same computer that access to the \\computername computer. help would be greatly appreciated. ...

81. How to create file on server?    java-forums.org

Hello there, I have one ruby web application in which i use java program to create file on linux server. The program got executed successfully but file is not created in folder that i specify. Following is my java code that i used to create file on server: import java.io.*; import java.lang.*; public class Test { public Test() {} public static ...

82. How to implement java files in resin server?    forums.oracle.com

83. I need to create and modify file to a server    forums.oracle.com

I trying to write a system demon that runs on the server 24 hours a day and listens to a specified port. When one of my applets wants to write a file, it opens a socket on that port on the server, sends commands saying what it wants to do, gives the filename, and then sends the data. But the problem ...

84. Unexpected end of file from server    forums.oracle.com

Can someone confirm if this is an issue with the code being passed or if it is an issue with the applet? It seems that I may be receiving this message when I have more than one web app open that uses java. I am not a java developer but I am just looking for some help, tell me if more ...

85. Dealing with Files on server    forums.oracle.com

Hi, I need to develop the functions below for a server in Java for swing. Is there any package or class that I can use ? I just had a look at one namely... com.mindbright.net.ftp. Can you guide me about developing these functions below:- 1) Retrieve file from server 2) Add, edit, delete a file from server. 3) upload / download ...

86. File retrieve issue from application running multiple application server    forums.oracle.com

Hi All, I am working with a project, where user can upload video files. The application is running two server to balance load. The issue is when admin wants to see all uploaded files. Issue detail ************* Two app server. A and B. Currently running in app server A. Both server has a directory /data, where all files gets stored. When ...

87. Create file on server.    forums.oracle.com

88. Need to convert MS Office files on the server itself.    forums.oracle.com

I'm writing a web app using JSP with Tomcat5.5 as server.Users upload MS offce files on the server and when the manager accepts then I want the uploaded files to be converted to PDF's in the background and stored at the server itself.for this I have PDFCreator.exe or PDF4U driver. If I do this using standalone Java program and exexuting the ...

89. List of file on web server    forums.oracle.com

90. Retrieving file from a file server.    forums.oracle.com

Hi All, Could some body give me the sample code for doing the below requirement. i have to retrieve a pdf file from a different machine(not on the machine where web server is located)..and send the same to a requested client by using a jsp.(browser). i will be passing the respective file name when i request... Regards, Naveen

91. File Based Multithreaded Web Server Question    forums.oracle.com

if (root == null) { root = new File(System.getProperty("user.dir")); } if (timeout <= 1000) { timeout = 5000; } if (workerThreads > 25) { printString("\n"); printString("#####################################################################"); printString("\n"); printString("Too many Threads!!!Maximum number of Worker Threads can be 15 only"); printString("\n"); printString("#####################################################################"); workerThreads = 15; } if (log == null) { log = System.out; } } }

92. How to get last modified date and time of a file which is in apache server.    forums.oracle.com

Hi , I need to get last modified date and time of a file in remote machine. This file is in remote machine which has apache server installed. I am trying to get this information by connecting to apache server from client by giving absolute URI of the file to file object. URI is got from apache server URL by using ...

93. Problem running .sh file on server with runtime.exec()    forums.oracle.com

Hi, I wrote a program which will use ffmpeg to convert media files. Media files can be converted with this string array being passed in to Runtime.getRunTime().exec: String cmd[] = {ffmpeg path, "-i", input file, output file}; However with the above method I couldn't set any options like "-s 176x144" for the output file's resolution, meaning if I use the following ...

94. Server side file not loading    forums.oracle.com

95. File Server    forums.oracle.com

The best thing you can do is find an existing product and use it. I'll bet their are free open-source ones. Or you can just pay for one. If you want to do it yourself, you're going to need to ask yourself a lot of questions. The first one would be, what are these "clients" you speak of? Do you mean ...

96. How to convert files from server in JODConverter?    forums.oracle.com

Is it possible to convert a web path to a format that is readable as file. the file is: http://localhost:8080/psf/Documents\abin\blog.txt I need to put this in an input box of type file. The reason being, I am using JODConverter to convert certain files to different format... However, when i try to use the path given above instead of the regular

97. Running class files on a server.    forums.oracle.com

Hi Guys, I have a class file (works fine) which takes data from a data base table and writes it out to an XML file. I tested it on my local machine using the tomcat server and it runs just fine. Next thing I want to do is run it on my server which is Java enabled, I am currently hosting ...

98. How do I upload/Download files to/from a server?    forums.oracle.com

I need to develop an interface which gives upload.download facility to the end user.I heard about multipart request and jakarta third party tool.But i dont know much about these two.So can anyone please suggest me which one is better and where will i get the more information about it.And also suggest me how to develop this interface. Thankyou very much in ...

99. run config file in server for each user    forums.oracle.com

hello all I have a Linux server and many terminals. In this server, I have a java application. From a terminal, an user can login into this server. When an user login, he will be at his folder called /home/username. He then run the Java application from his terminal. When the application run, it MUST open a config file for this ...

100. Bat File execution Problem in Win Server 2k3    forums.oracle.com

I have a jar that is calling a .bat file. It executes the bat file in Windows XP, and Windows 2000 But when I run it in Win Server 2k3 it can't execute. I get Exit Value 1 Does anyone know any differences between the Operating Systems that could cause this? Thanks Paul

java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.