How to control another TK application

I want to validate strings displayed in a TK application, how can I
write rb program to communicate to it and extract the messages from GUI?
Any module is good for that?

From: Liang He [email protected]
Subject: How to control another TK application
Date: Thu, 25 Oct 2007 15:48:09 +0900
Message-ID: [email protected]

I want to validate strings displayed in a TK application, how can I
write rb program to communicate to it and extract the messages from GUI?
Any module is good for that?

Do you mean about validation on TkEntry widgets?
If so, please read ‘tk/sample/demos-en/entry3.rb’.

Hidetoshi NAGAI wrote:

From: Liang He [email protected]
Subject: How to control another TK application
Date: Thu, 25 Oct 2007 15:48:09 +0900
Message-ID: [email protected]

I want to validate strings displayed in a TK application, how can I
write rb program to communicate to it and extract the messages from GUI?
Any module is good for that?

Do you mean about validation on TkEntry widgets?
If so, please read ‘tk/sample/demos-en/entry3.rb’.

Hi,
We have a separate tk based application running(can be initialed by Ruby
script), my task is to write a Ruby program to take the control of it
and validate the display, function, and browse from gui to gui. It is
much like how Watir do to web browser. Do you have any idea how can I
implement it?

Thanks!

From: Liang He [email protected]
Subject: Re: How to control another TK application
Date: Thu, 25 Oct 2007 17:07:04 +0900
Message-ID: [email protected]

We have a separate tk based application running(can be initialed by Ruby
script), my task is to write a Ruby program to take the control of it
and validate the display, function, and browse from gui to gui. It is
much like how Watir do to web browser. Do you have any idea how can I
implement it?

Hmm…
If your environment is Unix/X and Tcl/Tk’s “send” command is
available, ‘remote-tk.rb’ may help you.
Then, please read ‘ext/tk/sample/remote-ip_sample.rb’ and
‘ext/tk/sample/remote-ip_sample2.rb’.

If you use Windows, you may need Tcl/Tk’s “dde” command.
Please read Tcl/Tk’s manual of “dde”.
On Ruby/Tk, call “require ‘tk/winpkg’”.
TkWinDDE module supports it.
To control your Tk based application, you will have to modify
your application to register it as a DDE server.