Abel
Abel

Reputation: 57159

What's a good, if any, .NET Windows automation library?

I'm looking for a library that can be used in native .NET code, just like any .NET assembly. The purpose of the library must be to automate Windows (push a button, select a window, send keys, record & playback, that sort of thing).

So: the library is supposed to be used natively in .NET, but the automation itself must be able to target any native or .NET Windows application that can receive user input.


Suggestions so far:

If nothing else appears available, I'll probably choose Microsoft's UI Automation and upgrade any projects that require it that are still in .NET 2.0 to .NET 3.5, if possible. But I hope for a more widely applicable automation framework (.NET prior to 2.0 does not need to be supported).

Upvotes: 39

Views: 25119

Answers (9)

Apoorv
Apoorv

Reputation: 2043

I would still suggest FlaUI for autoamating .Net Desktop,Mobile apps. Its based on Microsoft UIA libraries and have support for external controls like the DevExpress Grid too Moreover, it is built on top of TestStack.White so indeed a very good library and has a github page also

Upvotes: 2

SwDevMan81
SwDevMan81

Reputation: 49978

Check out Tools for automated GUI testing on windows

Upvotes: 2

Bill Agee
Bill Agee

Reputation: 3646

If you haven't seen it yet, and a commercial library is acceptable, you might check out Ranorex:

http://www.ranorex.com/

I used Ranorex 1.5 quite a bit to write small C# UI automation utilities. It was pretty effective! Development seemed faster compared to using the MS UI Automation API directly, since Ranorex has a lot of useful convenience methods already available.

I haven't used Ranorex 2 very much yet, though.

In Ranorex 1.5, there was also support for traditional Win32 development in C++, but I didn't use it. As far as I know, that's still available in Ranorex 2.

I can't speak to the quality of the record/playback support in Ranorex since I never used that feature.

One final plus: Their support team was really responsive and helpful anytime I emailed them.

Upvotes: 3

t0mm13b
t0mm13b

Reputation: 34592

How about CSharpScript, here's an article about it on Codeproject, and here's the link to the main website. Furthermore, it is familiar C#, scripted which can be used to automate anything.

Hope this helps, Best regards, Tom.

Upvotes: 1

Unmesh Gundecha
Unmesh Gundecha

Reputation: 560

Have you looked at the White framework?

Upvotes: 11

pm100
pm100

Reputation: 50120

microsoft's own built in one is fine

http://msdn.microsoft.com/en-us/library/ms747327.aspx

not restricted to wpf as some seem to think.

Upvotes: 8

Chris Dunaway
Chris Dunaway

Reputation: 11216

This library is pretty interesting and is fairly simple. Perhaps it will help you.

Upvotes: 2

JasonTrue
JasonTrue

Reputation: 19609

I have used WebAii from ArtOfTest with a fair degree of success in automating integration testing for a Silverlight app. It also supports WinForms and Web applications.

Microsoft UI Automation, the successor to Active Accessibility, can do almost all of the Windows UI automation you would need.

Upvotes: 1

benPearce
benPearce

Reputation: 38333

I have used AutoIt in the past with success.

Upvotes: 8

Related Questions