Solved

Lauch a GUI remotely using Java and later kill it

Posted on 2003-11-06
4
305 Views
Last Modified: 2006-11-17
Hi
All
I need to launch a GUI remotely on another machine.
I am working on Java on Windows to obtain this.This should also be complaint with windows operation system also.
Also I need to kill the gui launched remotely to the same machine some time later.
  Can you some body help me with this.
Regards,
Naps
0
Comment
Question by:napsok
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 3

Accepted Solution

by:
mvoelker earned 35 total points
ID: 9700729
That's kinda tricky, especially under windows and java, since there is no "standard" or "native" way to do it.

Say you have machines A and B with A invoking the GUI on B. One way to accomplish this would be to have a non-gui process (jave program) running on machine B that listens for a network connection on some port (or use RMI). When A connects over the network to that process on machine B (and probably sends a specific command string or whatever), the process on machine B would that start the GUI. To stop/hide the GUI, you would simply send a different command string to the process on machine B. This whole method is incredibly insecure, but that's a different topic.

You'll have to think about some general points though: what happens if there is no user logged into machine B? Which user-ID/privileges should the gui application have? How secure does the solution have to be?

Regards,

 - michael
0
 
LVL 30

Expert Comment

by:Mayank S
ID: 9712699
Yeah, like Michael said, you need two programs - one client and one server. The client will run the GUI part and the server will accept connections (use a ServerSocket for this). For navigating across the GUI, you will need to issue commands and exchange messages between the two programs. You can make the server program multithreaded, so that it starts a new thread for every client.

Hope that helps!

Mayank.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There is an easy way, in .NET, to centralize the treatment of all unexpected errors. First of all, instead of launching the application directly in a Form, you need first to write a Sub called Main, in a module. Then, set the Startup Object to th…
Windows Script Host (WSH) has been part of Windows since Windows NT4. Windows Script Host provides architecture for building dynamic scripts that consist of a core object model, scripting hosts, and scripting engines. The key components of Window…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question