Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re^2: Win32::GuiTest control id

by abt (Novice)
on Jan 27, 2013 at 17:25 UTC ( #1015581=note: print w/replies, xml ) Need Help??

in reply to Re: Win32::GuiTest control id
in thread Win32::GuiTest control id

I am not supposed to use any of these Tools. But to make things better i have a list of Controlids. It's just the clicking and pushbutton that do not respond. Well some collegae told me that the list he gave me where the control id's. And if I have to use a tool to read the ID's, I am far from flexible. I coe across similar programs that can differ sligthly and new versions where the devolpers have the freedom to change the ID's That will make my task impossible for that means for every verion of every similar ( not exatly the same) program a offline check.

Replies are listed 'Best First'.
Re^3: Win32::GuiTest control id
by dasgar (Priest) on Jan 28, 2013 at 05:25 UTC

    It kind of sounds like you're trying to automate something for use at your work. If your employer has given you the task to do this automation work, then I personally believe that they need to provide you with what you need. In this case, that would be the use of a utility like the ones I suggested or you need access to key information from the source code. Of course, I've never been employed as a programmer before, so I guess there's a chance that I might be wrong about that.

    Given the restraints that you're claiming that you have to work within, here's my thoughts on what to try.

    First, you can check out the spy-- and spy examples from the Win32::GuiTest module. If you have Perl installed along with Win32::GuiTest, you already have those "installed". Just run them and see if those can help you out.

    Secondly, you can try to use Win32::GuiTest module to come up with some code of your own to explore the window GUI object of the application that you're trying to automate. To help you get started, you can start with something like the code below. Of course, you will need to make some modifications to use your desired program instead of calc.exe. Also, you may need to dig deeper into the windows structure, but this should help get you started.

    Out of curiosity, when you manually use the program that you're trying to automate, can you fully run that program using only the keyboard? If so, I would suggest punting on using PushButton and MouseClick functions. Instead, just go with the SendKeys function, which is providing "keyboard" input to the GUI based application.

      I can not fully control the program using a keyboard and more over, the program is part of a family of programs that are subject to change. The basic structure is there, but buttons and menu is subject to change. Problem is that the control-id's are provided, but doesnt seem to work.

        Stop guessing what these things are, don't assume the list you have been given by someone is correct, use the tools provided with Win32::GuiTest to discover what the control IDs actually are. If they're subject to change, you'll need to keep your automation code up to date with any changes to this.

Re^3: Win32::GuiTest control id
by Anonymous Monk on Jan 28, 2013 at 02:23 UTC

    I am not supposed to use any of these Tools.

    Sure you are

    And if I have to use a tool to read the ID's, I am far from flexible.

    Funny -- because you know what the alternative is? Not doing the job at all

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1015581]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (14)
As of 2018-07-17 15:35 GMT
Find Nodes?
    Voting Booth?
    It has been suggested to rename Perl 6 in order to boost its marketing potential. Which name would you prefer?

    Results (372 votes). Check out past polls.