File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Swing / AWT / SWT and the fly likes how do i capture  screenshot via network  in java swing Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "how do i capture  screenshot via network  in java swing" Watch "how do i capture  screenshot via network  in java swing" New topic
Author

how do i capture screenshot via network in java swing

Shashika Thiran
Greenhorn

Joined: Jan 22, 2009
Posts: 24
I want to get screenshot from another computer moniter via network.
I know how do it in same computer moniter.
like this

Dimension screenSize =
Toolkit.getDefaultToolkit().getScreenSize();
Rectangle rectangle = new Rectangle(0, 0, screenSize.width,screenSize.height);
Robot robot = new Robot();
BufferedImage image = robot.createScreenCapture(rectangle);

File file = new File("screen.png");
ImageIO.write(image, "png", file);

any one can help me to get screenshot via network....thanks.
salvin francis
Ranch Hand

Joined: Jan 12, 2009
Posts: 928

Simple, Write a java program that captures a screen shot on current computer.

now let the program to execute in the client machine listening at a socket for a "sendPrintScreen" Request.

Make a server program that has the ability to send this request to client and get response as a file sent via the network.

use TCP Ip

My Website: [Salvin.in] Cool your mind:[Salvin.in/painting] My Sally:[Salvin.in/sally]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how do i capture screenshot via network in java swing