Hi. I have 2 questinos. I have a html page that has a button "Start Log Server" which calls a servlet to kick off SocketServer. This SocketServer logs to a specified file on the server. Now, what I want is to have another button on the html page "shut down Log Server" that will shut down the SocketServer. When a user hit this button, I would like SocketServer to go down exactly like hitting Ctl-C when running SocketServer for console appender from command line. How can I kill the SocketServer?
2nd question is actually same as 1st one, but my attempt failed to bring socketServer down so... I made a ServerSocket variable as static class variable, and added a new method "CloseSocket()" to close the SocketServer. But, when a client program execute such a static method, ServerSocket variable is null and throws an exception... (in the SocketServer's main method, I have a check on serverSocket variable and if serverSocket is closed, get out the SocketServer app.) So.. (this one is more of a psudo-code) class SocketServer { static ServerSocket serverSocket; : static void main(args[]) { // start the socket server and initialize serverSocket } static CloseSocket() { serverSocket.close(); } } class SocketClient { static void main(args[]) { SocketServer.CloseSocket() // serverSocket is null.. } } I am using 1.1.3 of log4j on win 2000. Thanks!!! __________________________________________________ Do You Yahoo!? Make a great connection at Yahoo! Personals. http://personals.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]