The Artima Developer Community
Sponsored Link

Java Answers Forum
Action Listeners

1 reply on 1 page. Most recent reply: Nov 17, 2005 10:14 PM by Matthias Neumair

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 1 reply on 1 page
steve chu

Posts: 14
Nickname: chuchutrai
Registered: Nov, 2005

Action Listeners Posted: Nov 17, 2005 8:00 PM
Reply to this message Reply
Advertisement
Is it possible to write a Java program that Listens for a Save Action in another program and then starts running? For example, when you save in Word or something then my program detects that Save action and then starts doing what it has to do? is this possible? if yes then how would i implement it


Matthias Neumair

Posts: 660
Nickname: neumi
Registered: Sep, 2003

Re: Action Listeners Posted: Nov 17, 2005 10:14 PM
Reply to this message Reply
Not directly.

If you are watching one specific file you can use a timer to get informations about the file, in this case: 'last time changed'. If this info alters, then you can launch whatever you do. However, if it should look like real time, you need small timer intervals, which means high processor usage.

I would try to write a COM port for a Java program (try JIntegra for creating and accessing COM functions using Java) and to write something in word that accesses that method when saving. Don't know which sort of scripts Word supports.

Flat View: This topic has 1 reply on 1 page
Topic: Most Efficent method to transfer Data from Result Set object to flat file Previous Topic   Next Topic Topic: Getting main loaded class

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use