Obtain control names in Windows application - com

Haven't found this in my search on Stackoverflow - I know I've seen a tool like it before, for obtaining control names or IDs in Windows apps which can then be used for reference in automated testing, in tools like AutoIt. Can anyone suggest one?
I've tried the OLE/COM Object Viewer and while it has control lists, there's no interactive method with it. Like the web developer toolkit in Firefox where you can click a control and get all the information about it, I'm after a similar app for Windows testing.

It's called Spy++.

Found the tool I wanted, either NUnitForms - which means you can use the NUnit Framework to access windows forms, and includes a Recorder tool for identifying the controls, as well as Managed Spy for giving the individual component names as well as every bit of other info - font, color, size. Very nice.
NUnitForms : http://nunitforms.sourceforge.net/
ManagedSpy: http://msdn.microsoft.com/en-us/magazine/cc163617.aspx

Related

How to design UI using Automation Anywhere?

I'm planning to create a simple program that would automate the process by searching the dynamic list inputted and provided by the user and export it to Excel file.
The challenge is How to create UI using Automation Anywhere Application, that would accept adding the input value from the user like same controls in .Net (buttons, textbox, messagebox, etc...)
Does anyone knows how to attain it?
Automation anywhere does not provide the functionality to create a UI, as the technology makes use of the existing infrastructure, highlighting the non intrusive nature of the Robotic Process Automation or (RPA) tool.
I'm sure you will be able to create a simple UI using VBA/VB.net which should get the work done. ( Like the one below)
Using the UI you can use the plethora of commands in the Automation Anywhere command library to interact with your UI and automate the process.
I know this is an old post, hope that helps !!

Mac Post Events to specific background windows

I am trying to create an accessibility app that will type in multiple windows at once, neither of which are owned by my app. For instance, let's say you have two Microsoft word documents open. When you hit a keystroke I want the command to go to both windows.
I have tried using Quartz events services, but it looks like it will only allow you to post to events either on a global or process level. But if two windows are running for the same process, how do I post to a specific window?
There's also the issue of the person typing in one window, while the content is being copied to the next.
Is it possible to post to a single window?
PS I know it's possible to do this in Windows
MacOS X includes a few tools which may be helpful. You should look into the Accessibility framework, Automator actions, and AppleScript. You should also be aware of application-specific solutions; in the case of Word, for example, you might look at VBA (Visual Basic for Applications). All of these tools provide ways that you can modify the content of other applications. Unfortunately, the level of support for each one varies from one application to another, and the way they're used also varies. So, it's unlikely that you'll find a single solution that works for all applications.
It's unlikely that you'll find a way to insert events directly into another process's event queue. That'd be a huge security hole, for one thing. Even if you could do that, you really wouldn't be able to target specific windows with your events. Mac applications use a responder chain that sends keystrokes to the "first responder", usually a component of the active window.

"Guided Access" equivalent

I have to develop a windows store app which will be usable on public devices, that means users aren't supposed to be able to quit my application.
On iOS devices, an option called "Guided Access" allows to do this easily, buttons are disabled and you can specify an area where user can interact.
After some researches, I haven't found a way to do that, it seems that Microsoft has not implemented this option in Windows 8, so I'm looking for a way to do this with some code, directly in my app but I have no idea on how to do that precisely. Please, can you tell me if it's possible and, if it is, can you give me a point where I can start ?
Thanks.
I´m not sure whether or not this made it into the newly released preview of the Windows 8.1 Update, but check for "Assigned Access" it was rumored to be a new feature especially for Windows store apps
Edit: See the offical 8.1 product guide here, it only mentions it two times but maybe it is worth installing the preview.

Hooks in Windows 8 apps

I am trying to extract UI data from a Windows Store App. So far I have tried SetWinEventHook but have had little success. I have also tried to install a setWindowsHookEx hook into a windows store app, but it returns a 0.
MSDN has very little documentation available on this topic. What is the best way of hooking a metro app? Also if there is any other way to extract UI data?
Links:
http://community.nvda-project.org/ticket/1801
http://forum.nektra.com/forum/viewtopic.php?f=9&t=6228
Have not been able to figure out how the above links got this done.
Why are you trying to do this with a window hook? Most store apps don't use standard windows controls (they don't have windows in the normal sense).
I would try UI automation to enumerate the visible controls and interact with them, that might work.

how to get embedded flash movie to communicate with .net winforms app

Hi I've used the shockwave flash com object to embed my flash file. I have buttons you can click on within the flash movie. Is it possible to get flash to notify my winform app which button has been pressed. It's developed using actionscript3. I'm using the latest vb.Net.
You can either use FSCommand, or use ExternalInterface. The later is better, although it may be harder to understand at first because of the format it uses, although if you've already solved the CallFunction (or SendFunction?) method argument, it's the same.
There are documentation and a sample C# project in Adobe's site, but I don't know the exact URL.
EDIT: To catch FSCommand and ExternalInterface calls there are two events you can subscribe to.
Also, you could also use sockets (either binary or XML).
That's a very open question as there would be many ways to do this depending on how your website and winforms applications are setup.
My initial suggestion would be to have your flash movie call some client side javascript on the button clicks. The javascript could post to a .Net SOAP webservice for instance which logs the button interaction to an associated database. Then your winforms application could finally check the database for the presence of new button click records.
This is just one high level suggestion based on the very high level question asked. If there's more specific information available then this can be refined.
Brian.