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 ... |
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 ... |
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 ... |
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 ... |
Any Java API in client side can check its modified date?
|
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 ... |
When coding in java,
How to get the corresponding file extension if the mimeType of the file is known?
|
|
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. ... |
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 ... |
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 ... |
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. ... |
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 ... |
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 ... |
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 ... |
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 ... |
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, ... |
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 ... |
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 ... |
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 ... |
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.
|
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 ... |
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 ... |
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?
|
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 ... |
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 ... |
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 ... |
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 ...
|
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 ... |
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 ... |
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 ... |
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 ... |
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 ... |
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 ... |
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 ... |
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 ... |
|
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 |
|
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 |
|
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 ... |
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 ... |
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 ... |
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 ... |
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 ... |
|
|
|
|
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 ... |
|
|
|
|
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 ... |
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 ... |
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 ... |
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 ... |
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 ... |
|
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 ... |
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 ... |
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? ... |
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, ... |
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 ... |
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 ... |
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 ... |
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, ... |
|
|
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 ... |
'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' ... |
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 ... |
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 ... |
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 ... |
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 ... |
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 ... |
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. |
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 ? |
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. ... |
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 ... |
|
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 ... |
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 ... |
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 ... |
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 ... |
|
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 ... |
|
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 |
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; } } } |
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 ... |
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 ... |
|
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 ... |
|
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 ... |
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 ... |
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 ... |
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 |