# Controlling other applications functionality

**URL:** <https://www.ruby-forum.com/t/controlling-other-applications-functionality/179218>\
**Category:** Ruby\
**Created:** [November 19, 2009, 9:24pm UTC](https://www.ruby-forum.com/t/controlling-other-applications-functionality/179218 "2009-11-19T21:24:52Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sepehr](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/858c86/32.png) [@sepehr](https://www.ruby-forum.com/u/sepehr)\
**Post date:** [November 19, 2009, 9:24pm UTC](https://www.ruby-forum.com/t/controlling-other-applications-functionality/179218/1 "2009-11-19T21:24:52Z")

</div>

## How can I access an applications objects and call their functions programmatically using ruby? for example suppose there is a button in an application which performs a task, I want to press that button with my ruby script, how is this done?

Thanks in advance

---

<div class="post-metadata">

**Author:** ![sepehr](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/858c86/32.png) [@sepehr](https://www.ruby-forum.com/u/sepehr)\
**Post date:** [November 19, 2009, 9:30pm UTC](https://www.ruby-forum.com/t/controlling-other-applications-functionality/179218/2 "2009-11-19T21:30:53Z")

</div>

Mehdi K. wrote:

> ## How can I access an applications objects and call their functions programmatically using ruby? for example suppose there is a button in an application which performs a task, I want to press that button with my ruby script, how is this done?
> 
> Thanks in advance

Depends largely on the nature of the receiving application. Can you  
provide more detail about what you want to control?

## Best,

Marnen Laibow-Koser  
[http://www.marnen.org](http://www.marnen.org)  
removed\_email\_address@domain.invalid

---

<div class="post-metadata">

**Author:** ![sepehr](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/858c86/32.png) [@sepehr](https://www.ruby-forum.com/u/sepehr)\
**Post date:** [November 19, 2009, 9:39pm UTC](https://www.ruby-forum.com/t/controlling-other-applications-functionality/179218/3 "2009-11-19T21:39:27Z")

</div>

Marnen Laibow-Koser wrote:

> Mehdi K. wrote:
> 
> > ## How can I access an applications objects and call their functions programmatically using ruby? for example suppose there is a button in an application which performs a task, I want to press that button with my ruby script, how is this done?
> > 
> > Thanks in advance
> 
> Depends largely on the nature of the receiving application. Can you  
> provide more detail about what you want to control?
> 
> ## Best,
> 
> Marnen Laibow-Koser  
> [http://www.marnen.org](http://www.marnen.org)  
> removed\_email\_address@domain.invalid

Well ,there is this application called Progdvb which is used to watch  
satellite channels , I want to programmatically call its record button  
at a certain time and recall again to stop recording  
PS: I have whole bunch of needs too, for example I want to control some  
functionality of my download manager(Flashget) , could you share more  
light on \>\>“Depends largely on the nature of the receiving application”  
what do I need to consider for this process?

---

<div class="post-metadata">

**Author:** ![sepehr](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/858c86/32.png) [@sepehr](https://www.ruby-forum.com/u/sepehr)\
**Post date:** [November 20, 2009, 1:09pm UTC](https://www.ruby-forum.com/t/controlling-other-applications-functionality/179218/4 "2009-11-20T13:09:07Z")

</div>

Mehdi K. wrote:

> PS: I have whole bunch of needs too, for example I want to control some  
> functionality of my download manager(Flashget) , could you share more  
> light on \>\>“Depends largely on the nature of the receiving application”  
> what do I need to consider for this process?

What OS do you use, what’s your Ruby version, do you only want to  
control buttons… Things like that.

If you want a library to simulate user input (with Ruby 1.9), you may  
have a look at my xdo (for Linux) and au3 (for Windows) libraries. You  
can find it on RubyForge at [http://rubyforge.org/projects/auto/](http://rubyforge.org/projects/auto/) .

Marvin
