what can you automate with Ruby?

Discussion in 'Ruby' started by Chris Finch, Sep 7, 2006.

  1. Chris Finch

    Chris Finch Guest

    Hi all,
    I'm a newbie - please have patience.

    I am not sure if anyone uses Ruby as an automation tool - I think it
    would be a cool thing to do.

    I have heard of the WIN32OLE extension - it sounds cool - does anyone
    use this and why?

    I was wondering if this automation only applies to these Windows
    applications or is there any more you can control with a Ruby program?

    I use the graphing application Origin - could I use Ruby to automate,
    i.e. put data in and plot graphs.

    Thanks in advance,

    Chris

    --
    Posted via http://www.ruby-forum.com/.
     
    Chris Finch, Sep 7, 2006
    #1
    1. Advertising

  2. Chris Finch

    Jan Svitok Guest

    On 9/7/06, Chris Finch <> wrote:
    > Hi all,
    > I'm a newbie - please have patience.
    >
    > I am not sure if anyone uses Ruby as an automation tool - I think it
    > would be a cool thing to do.
    >
    > I have heard of the WIN32OLE extension - it sounds cool - does anyone
    > use this and why?
    >
    > I was wondering if this automation only applies to these Windows
    > applications or is there any more you can control with a Ruby program?
    >
    > I use the graphing application Origin - could I use Ruby to automate,
    > i.e. put data in and plot graphs.
    >
    > Thanks in advance,
    >
    > Chris


    It depends on what you want to automate. Ruby can do (almost) anything
    any other language can - on windows that means COM, commandlines,
    WIN32API, registers, etc.
    You can even automate GUIs via AutoIt .dll/COM interface, although in
    most cases pure AutoIt is easier.

    There is watir package to control/automate the browser if I've
    understood it correctly.

    On unix, the possibilities are similar, so the main question is, what
    means/protocol/whatever you need to use to automate your target?
     
    Jan Svitok, Sep 7, 2006
    #2
    1. Advertising

  3. Chris Finch

    Chris Finch Guest

    > If an automation facility exists

    Is there a standard way to find out if an application enables
    automation? or can you suggest a way?

    > if the
    > facility is reasonably flexible


    Could you expand upon this please?

    Thankyou
    Chris


    --
    Posted via http://www.ruby-forum.com/.
     
    Chris Finch, Sep 7, 2006
    #3
  4. Hi Chris,

    Coincidentally, I am also a Ruby Newbie, and just found out about
    WIN32OLE. So far, the documentation I've found is very spare. One
    trick I did learn in combing through the web was to use your system to
    print out the methods available for the various applications:

    require 'win32ole'

    # Win32OLE Variables
    excel = WIN32OLE.new('Excel.Application')
    word = WIN32OLE.new('Word.Application')

    puts excel.methods
    puts "\n\n"
    puts excel.ole_methods

    puts word.methods
    puts "\n\n"
    puts word.ole_methods
    puts "\n\n"
    puts word.Documents.ole_methods

    This gave me at least a start. You might also want to look at the help
    file that is available on Office Automation at
    http://support.microsoft.com/kb/302460/.

    If anyone else has any information on Office Automation, and
    specifically how it fits into Win32OLE, I'd really appreciate it - what
    I'd really like to have is a "canonical" list of all methods for each
    available Office module. But I haven't found anything close to that
    yet.

    James


    Chris Finch wrote:
    > Hi all,
    > I'm a newbie - please have patience.
    >
    > I am not sure if anyone uses Ruby as an automation tool - I think it
    > would be a cool thing to do.
    >
    > I have heard of the WIN32OLE extension - it sounds cool - does anyone
    > use this and why?
    >
    > I was wondering if this automation only applies to these Windows
    > applications or is there any more you can control with a Ruby program?
    >
    > I use the graphing application Origin - could I use Ruby to automate,
    > i.e. put data in and plot graphs.
    >
    > Thanks in advance,
    >
    > Chris
    >
    > --
    > Posted via http://www.ruby-forum.com/.
     
    James Calivar, Sep 7, 2006
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Cirene

    How do you automate a process?

    Cirene, Nov 3, 2007, in forum: ASP .Net
    Replies:
    6
    Views:
    342
    Cirene
    Nov 5, 2007
  2. Aldo Ceccarelli
    Replies:
    0
    Views:
    498
    Aldo Ceccarelli
    Mar 19, 2009
  3. Tester in ruby
    Replies:
    1
    Views:
    246
    Dave Burt
    Oct 14, 2005
  4. Vincent Foley

    Using Ruby to automate Windows tasks

    Vincent Foley, Jan 13, 2006, in forum: Ruby
    Replies:
    2
    Views:
    223
  5. Simon Jackson

    can ruby automate form submission?

    Simon Jackson, Feb 23, 2007, in forum: Ruby
    Replies:
    2
    Views:
    197
    Simon Jackson
    Feb 23, 2007
Loading...

Share This Page