Scripting 3rd Party Application

Posted on 2003-12-04
Last Modified: 2010-04-14
First off, I'm not too experienced in scripting. Here's what I need to do:

I'm running a program called HotLine Server ( It's a free program that creates a community for exchange of files and chat. It has a window with control buttons that include one to reload, which causes it to reread an agreement file that remote users see when they log on. I need to click that button daily.

I tried to use Applescript GUI scripting. To identify the button I tried using UIElementInspector and Prefab UI Browser. The problem is that the buttons don't show up as elements in the window using these tools. The Maximize, Minimize, and Close buttons show as elements, as does the header text, but not the command buttons.

I tried using killall -HUP HLserver19 from a command line but the application doesn't like it. When it comes back the UI isn't running and it refuses connections. Is there any hope?

BTW, this is on a G4 running OS 10.3.1.

Question by:mwarbeck
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
  • 2

Expert Comment

ID: 9880651
Use QuickKeys!

Record a script that when that window comes up, it clicks the "ok" button (or whatever).  And then modify the script a little bit to make it infinitely loop, constantly waiting for that program to bring up the window again, just so it can click it.  =)  Isn't technology neat.

I used to use this program on OS-9 for doing this exact thing.  I used it to auto-close AOL disconnect windows, and to click hotline client register notices back with hotline client 1.0.  =P  Hehe... this is their OS-X version, and I just confirmed it works fine with 10.3 with their patch on their website.  =)  Enjoy

 - Insolence

Author Comment

ID: 9890141
Quickkeys may be an option. I've been playing with it for a few days but can't get the shortcut to run triggered by time and day. I can click the Run button and it executes but no matter what I do with the time it won't run. I close the shortcut editor window, saving the shortcup. I tried leaving the Quickkeys window open and I tried minimizing it. No matter what it doesn't run when the time condition is met. I even set it to run every 5 minutes but it just doesn't run on schedule. The shortcut has three steps: switch to the Hotline Server, click in the title bar of the window, then click on the button. Any ideas as to why it won't run by the schedule?

Expert Comment

ID: 9890889
Well, if you're running a hotline server, it should (usually) be on a server that you don't play with often.  It sounds like it's your desktop computer or something.  =P  In this case, good luck man.  If it is a server that no one usually has physical access, Quickkeys will do the job for you, I can guarantee it.  It's really as easy as hitting record, then clicking that OK button (or whatever) then hitting stop.  Then editing the script manually to run infinitely.  That doesn't always work... but if it doesn't, you can always write the script manually.  The quickkeys language is so simple...  =P  Do a "wait for window with title" and put in the title of that window, then do a "wait 2 seconds" or a "wait till system is idle", giving the script enough time for the window to fully come up, then tell it to press the return key, or tell it to move the mouse's coordinates to the button's location, and then click the mouse.  Run this in an infinite loop, and it'll constantly wait for that window to come up, just to click it.  This won't really work if you're trying to use it as a desktop computer and running hotline server in the background though.  =\  With some monkeying around it might...  =P

 - Insolence
PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now


Author Comment

ID: 9893304
Actually the test bed is a desktop G4. The actual server is a new G5. I had no problem running the script manually, just by the time trigger. I did three steps: switch to the application, click in the title bar of the window with the button I need, then clicking the button. I'm currently running it via an Applescript that is run by a cron job. This works as long as the screen saver is not active. Could the screen saver be hosing Quickeys timer, too? One last question then I'll accept the answer and award the points: Is Quickeys language documented anywhere?

Thanks for your efforts!

Accepted Solution

Insolence earned 500 total points
ID: 9902346
The screensaver actually does hose the timer for me.  =\  Yikes, never noticed that.  I usually let my monitor go to sleep and don't use screensavers so I never ran into that.  =P  And I don't think it's documented anywhere really.  It might be... but I've never seen it.  It seems decent enough to read it and figure out what most of it does though, but you're right, language documentation couldn't hurt.

 - Insolence

Expert Comment

ID: 9903655
And you are quite welcome mwarbeck.  =)

 - I

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

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

Create a default user profile for Mac OS X 10.7/10.8 Create a user account on OS X that will be a template for every other user of that computer. I usually call it “profile” and make it an administrator account for the time being. 1. Install a…
Set up iPhone and iPad email signatures to always send in high-quality HTML with this step-by step guide.
In this video, viewers are given an introduction to using the Windows 10 Snipping Tool, how to quickly locate it when it's needed and also how make it always available with a single click of a mouse button, by pinning it to the Desktop Task Bar. Int…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …

617 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