aspose file tools
The moose likes Swing / AWT / SWT and the fly likes Need for som directions Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Elasticsearch in Action this week in the Big Data forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Need for som directions" Watch "Need for som directions" New topic

Need for som directions

Farid Abdi

Joined: Dec 25, 2012
Posts: 12

I have an idea...
I want to load a picture ( map of a factory ) and spot some point on it ( Cisco Switches ) and bind a ping to each switch and displaying result on map in form of ( green for connected switches and red for disconnected switches )..
How i can do that ??
I know how to load an image on screen ( using ImageIcon and using JLabel from swing ) ....the things that i don't know is that how i can bind some action ( for example a ping command ) to may map ??? I need only the name of techniqe...If i know the name of techniqes and some brief explaine the i could develope the remain of project myself...thanks
K. Tsang

Joined: Sep 13, 2007
Posts: 2725

Well you already "bind an action" to the image (or a map should be more exact). Have you checked the API for ImageIcon if this is the class you plan to use for the image. Most Swing components can add action listeners.

And for the ping System.exec(...) calling command line ping command.

I agree. Here's the link:
subject: Need for som directions