Showing posts with label WinForm. Show all posts
Showing posts with label WinForm. Show all posts

Tuesday, May 06, 2014

Microsoft .NET Framework 4.5.2 Released

Microsoft Downloads - Microsoft .NET Framework 4.5.2 Developer Pack for Windows Vista SP2, Windows 7 SP1, Windows 8, Windows 8.1, Windows Server 2008 SP2 Windows Server 2008 R2 SP1, Windows Server 2012 and Windows Server 2012 R2

The .NET Framework 4.5.2 Developer Pack installs the multi-targeting pack for .NET Framework 4.5.2. Developers can build applications targeting the .NET Framework 4.5.2 using either Visual Studio 2013, Visual Studio 2012 or third party IDEs. You need to download the web installer instead of this package if you intend to redistribute .NET Framework 4.5.2.

Version: 4.5.2

File Name: NDP452-KB2901951-x86-x64-DevPack.exe

Date Published: 5/6/2014

File Size: 328.3 MB

The .NET Framework 4.5.2 Developer Pack is a single package that installs .NET Framework Multi-targeting pack for .NET Framework 4.5.2 and also .NET Framework 4.5.2. Developers can build applications targeting the .NET Framework 4.5.2 using either Visual Studio 2013, Visual Studio 2012 or third party IDEs.

You need to download the web installer from here instead of this package if you intend to redistribute .NET Framework 4.5.2.

This package installs the following components:

  • .NET Framework 4.5.2
  • .NET Framework 4.5.2 Multi-Targeting Pack:Contains the reference assemblies needed to build apps that target the .NET Framework 4.5.2
  • .NET Framework 4.5.2 Language Packs
  • .NET Framework 4.5.2 Multi-Targeting Pack Language Packs: Contains the IntelliSense files to display help while building apps that target the .NET Framework 4.5.2 through Visual Studio and third party IDEs.


The .NET Framework 4.5.2 runs side-by-side with the .NET Framework 3.5 Service Pack 1 (SP1) and earlier versions of the .NET Framework. However, the .NET Framework 4.5.2 is an in-place update to the .NET Framework 4.5.1, the .NET Framework 4.5, and the .NET Framework 4.

Please see the Knowledge Base Article KB2901951 for more information.
For important information about this release, see the .NET Framework 4.5.2 Readme File.


NOTE: As of my posting, the above KB and ReadMe are not yet online.
UPDATE: ReadMe and KB's are coming online as I write this...

I wonder if this was released early? I'd have thought that this would have been released next week, during TechEd NA? Not sure yet what's actually in it, more to follow as it becomes available...
UPDATE: According to my sources, the release was intention.

Update: What's New in the .NET Framework 4.5, 4.5.1, and 4.5.2

  • New APIs for ASP.NET apps. ...

  • Resizing in Windows Forms controls. This feature has been expanded. You can now use the system DPI setting to resize components of the following additional controls (for example, the drop-down arrow in combo boxes):


    This is an opt-in feature. To enable it, set the EnableWindowsFormsHighDpiAutoResizing element to true in the application configuration (app.config) file:...

  • New workflow feature. A resource manager that's using ...

  • Profiling improvements. The following new unmanaged profiling APIs provide more robust profiling: ...

  • Debugging improvements. The following new unmanaged debugging APIs provide better integration with a profiler. You can now access metadata inserted by the profiler as well as local variables and code produced by compiler ReJIT requests when dump debugging.


  • Event tracing changes. The .NET Framework 4.5.2 enables out-of-process, Event Tracing for Windows (ETW)-based activity tracing for a larger surface area. This enables Advanced Power Management (APM) vendors to provide lightweight tools that accurately track the costs of individual requests and activities that cross threads. These events are raised only ...


Related Downloads:

Monday, January 14, 2013

i00 Spell Check and Control Extensions, Stand alone, no third party components, offline... and free (and in VB too!)

CodeProject - i00 Spell Check and Control Extensions - No Third Party Components Required!

I wanted a spell check that I could use in .NET, so like most people would have done, I Googled. After many hours of fruitless searching, I decided to make my own; sure there are plenty of spell checkers out there, but I didn't want one that relied on 3rd party components such as Word or require Internet connectivity to work. Introducing i00 .NET Spell Check, the first and only VB.NET Spell Check written completely in VB! Not only that, it is also open source, and easy to use.

Eventually, this project progressed even further into a generic control extension plugin that provides plugins for text box printing, translation, speech recognition and dictation plus more; while also providing a simple method for users to write their own extensions.






The included projects and a brief description of each are as follows:

i00SpellCheck - Contains the classes for the spellcheck core / TextBox and DataGridView plugins plus the core components required for other plugins to work

Plugins\LabelPlugin - Contains a plugin that checks the spelling of Labels

Plugins\OSControlRenderer - Contains aplugin that renders the TreeView and ListViews to the same that they appear in Windows

Plugins\SelectedControlHighlight - Contains a plugin that extends a variety of Controls so that they appear to have a "glow" when selected

Plugins\TextBoxPrinter - Contains a plugin that extends TextBoxBase to support printing

Plugins\TextBoxSpeechRecognition - Contains a plugin that extends TextBoxBase to include support for voice input (double tap F12) and dictation

Plugins\TextBoxTranslator - Contains a plugin that extends TextBoxBase to support Google Translation





  • Added engine to make more generic control extensions
  • Changed the workings of SpellCheckControlBase to use the more generic control extensions
  • Default dictionary load is now threadded even when just calling .SpellCheck
  • Control extensions can now specify multiple ControlTypes
  • Put the TextBoxBase change case feature into its own control extension
  • Put the nicer TextBoxBase context menu into its own control extension
  • Made the window animations smoother and more stable for F7 etc
  • Control extensions can now be dependant on other control extensions (like references but within control extensions)


  • Added TextBoxPrinter plugin


  • Added buttons to trigger dictate and speech
  • Custom Karaoke rendering control added to test form
  • Now uses the new, more generic, control extension rather than extending SpellCheckTextBox
  • Speech is no longer "broken up" at the end of each line in Windows 8


  • Added OSControlRenderer plugin


  • Added SelectedControlHighlight plugin


  • Added TextBoxTranslator plugin

While written a couple years ago, the author continues to improve this library. And while Windows 8 has spell checking baked into the OS (finally) not everyone is on it yet (No, really! Some people are holding out and staying on Win7 for now! Yeah, I know... :P )

And I also know there's still a number of WinForm fans out there, let alone VB fan Dev's, so this is like a three for free post!

A nice touch are the C# examples. While written in VB, of course you can use it from C# app's too and having C# examples will help.

Friday, August 31, 2012

Infragistics gives their Windows Forms controls some Coded UI Testing love

Jason Beres - Announcing Coded UI Support for Windows Forms

"I am pleased to announce that we will be shipping CodedUI Test support for major controls in the upcoming NetAdvantage for Windows Forms 12.2 release slated for early October 2012. If you are not familiar with CodedUI Tests (CUIT), here is a summary from MSDN:

Automated tests that drive your application through its user interface (UI) are known as coded UI tests (CUITs). These tests include functional testing of the UI controls. They let you verify that the whole application, including its user interface, is functioning correctly. Coded UI Tests are particularly useful where there is validation or other logic in the user interface, for example in a web page. They are also frequently used to automate an existing manual test.

What Visual Studio gives developers and testers is an easy way to record and playback tests, which can uncover bugs or regression in the UI behavior. The reason that Infragistics controls do not work ‘out of the box’ with CUIT is simple – the CUIT infrastructure in the .NET framework doesn’t know what to do when a complex control with a nested hierarchy of UI elements is being tested. So we had to do a lot of work to make sure out controls work as you would expect.

When you install Windows Forms 12.2, and you’ll see that the CUIT feature will involve two main parts:

  1. A plug-in for the CUIT Framework
  2. UI Automation (UIA) implementation for Infragistics controls

The plug-in for the CUIT Framework will be a separate assembly we provide that tells the CodedUI framework to use UIA for Infragistics controls instead of the standard and limited MSAA which is not robust enough to handle Infragistics controls. As a result of adding UIA capabilities to our controls we will be able to better support CUIT but at the same time update our Accessibility support.

The architecture looks like this:


When Does it Ship & What Do You Get?

This will ship with v12.2 in October, so we are about 1 month away from getting this into your hands. Over the last 18 months we’ve surveyed customers who have expressed interest in CUIT support, and prioritized the order of the controls we worked on and are shipping in V1 of this feature. In October you will see support for:

  • Grid
  • Combo
  • Editors (Text, Numeric, DateTime, etc)
  • Combo Editor
  • Tab (high risk)
  • Tab Strip (high risk)
  • Drop Down
  • Button
  • Scroll Bars
  • Progress Bar

Our plan is to roll out CUIT support for controls with each monthly Service Release, so you will continue to get updates until we achieve 100% coverage over the next couple of releases.  The next major controls in the roadmap are ToolbarsManager, Ribbon & DockManager.


While WinForms might not be all the sexy, it's still got a place and I have to say sometimes it's just easier and quicker than WPF. Seeing this, I thought it great that this kind of additional support was coming from a third party control suite like this.

Saturday, August 04, 2012

THE open source WinForm & WPF docking library gets overhauled and a new version two, AvalonDock v2's!

AvalonDock - AvalonDock 2.0.1320

"Welcome to the first release of AvalonDock 2.0

Finally I can upload the new release of AvalonDock. This new release is stable and includes many new features if compared to 1.3:
  • AvalonDock 2.0 has been completely rewritten to take full advantage of the MVVM design.
  • The layout model is now completely separated from the view controls; integration with frameworks like PRISM is easier and faster.
  • I worked a lot to get the best performance especially when user move panes in floating window or set them as auto hidden.
  • Floating windows can now be arranged together as it's possible in VS2010.
  • The library itself is lighter because use only standard controls restyled like the TabControl or the Grid panel.
  • Since first beta I fixed a lot of bugs; this version should be stable enough for most of the projects.
  • Comes with two additional themes: VS2010 and Aero theme.




Hi all, I'm happy to announce that the first public release of AvalonDock 2.0 is published!

Here you can find some key concepts of the new version.

Project Description
AvalonDock is a WPF controls library which can be used to create a docking layout system like that is present in VisualStudio. It supports fly-out panes, floating windows, multiple docking manager in same window, styles and themes and it can host WinForms controls.
  • Supports MVVM design
  • Almost everything can be restyled
  • Support for Windows Forms controls


This is one of the libraries that is used in many projects yet doesn't always get the press and kudo's it's due. If you want docking windows behavior in your WinForm/WPF Desktop app's then you need to check out this library.


Related Past Post XRef:
AvalonEdit, a (the?) WPF code editor component from the SharpDevelop team (think WPF based, monster cool, code editing, IDE like, uber textbox +10)
Working Workflow into your app's. Workflow Studio, a source available example of rehosting the Workflow Designer

Saturday, May 12, 2012

Array Visualizer - VS 2010 Debugging array visualizer and WinForm/WPF control you can use too...

Visual Studio Gallery - Array Visualizer

"Array Visualizer is a free, open source extension for visual studio. It is designed to display 2D, 3D and 4D arrays while debugging an application.



CodePlex  - Array Visualizer

"Array Visualizer Controls & VS Extension

Array Visualizer is a set of WPF and WinForms controls that enable visualization of 2D, 3D and 4D arrays.

The Visual Studio Extension is provided for easy integration with the VS 2010 IDE and enables visualization of arrays at debug time. The extension can downloaded directly from Visual Studio Gallery or from within VS 2010.

Additional WPF and WinForms projects are provided to illustrate the use of the Array Visualizer controls leveraging the LINQ style array extension from the Linq Extensions Library.


There's a number of cool things here, the visualizer itself, that the source for it is also available and coolest, that it's actually a control you can use yourself in your app's...

Friday, February 24, 2012

WinForms MVP! (No, not that kind of MVP, MVP as in Model View Presenter...)

Moot Points - WinForms and MVP: Making a testable application

"With modern frameworks available that were built with loose coupling and separation of concerns in mind, working in WinForms may seem like a testability wasteland. But there are times when the options of WPF with MVVM or MVC on the web are not available, and you’re stuck with WinForms. But fear not, the Mode-View-Presenter pattern is here to save the day!

If you are not familiar with the MVP pattern, the idea is that you have a presenter, which handles all the interactions between the user and the model. The presenter “Talks” to the UI through an abstraction. There are a couple ways of doing the MVP pattern. I’m going to explore the Passive View style, meaning all logic is taken out of the view and moved into the presenter. I’m not going to go into differences in the styles, but if you’re interested, Martin Fowler has in depth descriptions of the Passive View, and Supervising Controller patterns, which are both derivatives of MVP.

I’m going to do a walkthrough for creating a simple MVP application. We need a premise for our demo. I’ll go with something simple, an application that organizes notes. Here our note will be a bit of textual data with a title. Lets implement it.



I'll say it, WinForms can rock! THERE! HA! Said it!

Seriously, I still find it so much easier to use WinForms when knocking out a test harness, PoC form, etc. Some of the simple things are just so much easier...  I know, I know, they are "dead" and have no future, but still sometimes they really are the right tool for the job.

Now marry that up with a good model like MVP...

Wednesday, December 21, 2011

Windows Forms Toolkit v0.2... A little WinForm love for the holidays...

CodePlex - Windows Forms Toolkit

"This project will provide many controls and tools for developing with Windows Forms.


Windows Forms Toolkit provide controls and tools to works easily with Microsoft Windows Forms.

Currently available controls :

  • Extenders
    • BalloonTipExtender: provide a extender to show balloon for TextBoxBase controls;
    • CueTextExtender: provide a extender to add cue text for TextBoxBase and ComboBox controls;
    • ValidatorExtender: provide a simple way to validate user entries (like;
  • Controls
    • ColorPalette is a control showing a customizable list of color;
    • SplitButton is a button control that propose a context menu for alternate options (like Microsoft Word open file dialog);
    • TabControl is a extend TabControl with many properties and events to improve experience;
    • NotificationForm can be use as base for create notification like Microsoft Outlook;
  • Data
    • DataTableConvertionExtensionMethods is a static class providing some Extension Methods to convert DataTable to Object... and Object to DataTable;
  • Drawing
    • RoundedRectangle draw rectangle with rounded corners;
  • Miscellaneous
    • HotKeysManager provide global HotKeys support for Windows Forms applications;
    • WatchDogRunner can run delegate with a limited time;


Call me a luddite, but for me sometimes WinForms is just easier and quicker. And it's nice to see the community still have some love for it... :)

Thursday, November 10, 2011

PDFViewerNet - OSS PDF WinForm viewer component (leverages GhostScript, XPDF or muPDF)

Christiaan Baes (chrissie1) - pdfviewernet, where have you been all my life?

I use the acrobat reader activex control to show pdf's in my winforms application. And yesterday I was bitching about it on twitter because it for some reason was blocking a folder on my buildserver every time I ran a build. At that point in time I could either choose to avoid the tests that made this happen or just use a hammer and get rid of the adobe acrobat reader at the end of my build. So I bitched about this on twitter, as one always does, and I got some very useful replies


And did you see the suggestion by the ever brilliant Jeremiah Peschka. So I did what he said and checked that project out.


You can find pdfviewernet on google code. First thing you'll note is that it is written in VB.Net which is brilliant. Second thing to note is that the downloads have a very old date on them. So I decided to install tortoisesvn again and compile against the trunk.

Sadly it isn't on nuget (yet).

This is very easy and if you then open and run it you even get a little demo app to play with.

I opened a pdf with it.




"VB.NET project that consists of a PDF Viewer control that can display any PDF file without having any Acrobat programs installed on the client. It can be configured to use GhostScript, muPDF or XPDF. "

I've only been watching for free/oss Windows PDF libraries/etc for forever and hadn't seen this before. Extra credit for being written in VB. :)

Saturday, October 29, 2011

Adding full Coded UI support to third party WinForm components that don't already have it...

Visual Studio ALM + Team Foundation Server Blog - Coded UI Test Extension for 3rd party Windows Forms controls–How to?

"Here is how one can add FULL Coded UI Test support for a 3rd party control based on Windows Forms technology.

Implementation Method – Accessibility

Accessibility means having equal access to web-based information and services regardless of physical or developmental abilities or impairments. Once implemented, it helps developers make their programs more compatible with accessibility aids (help users with impairment to use programs more effectively).

Microsoft has developed two accessibility standards - Microsoft Active Accessibility (MSAA) and Microsoft UI Automation (UIA)

MSAA is designed to help Assistive Technology (AT) products interact with standard and custom user interface (UI) elements of an application (or the operating system), as well as to access, identify, and manipulate an application's UI elements including enabling automation testing.

UIA is a newer technology that provides a much richer object model than MSAA, and is compatible with both Win32 and the .NET Framework. It is designed so that it can be supported across platforms other than Microsoft Windows.

We recommend MSAA for Windows Forms because Windows Forms natively supports MSAA and not UIA. Although there is MSAA to UIA & vice-versa conversion available via built-in proxy\bridge but the results in an extra layer of dependency which could eat into performance, hence MSAA.

Why Accessibility for Coded UI Test?

1. Implementing accessibility is simpler because one needs to follow established guidelines that serve the purpose of developing testable as well as accessible controls in one go

2. There is not much need to write an entire plugin for controls as much of the work is already done. We have built plugins for Windows Forms and Windows Presentation Foundation controls using accessibility technologies and have exposed appropriate extension points for easy hook-up

3. Vendors such as Telerik who develop 3rd party controls have already announced accessibility implementation

Detailed steps with reference to Coded UI Test Extension for 3rd party controls - the basics explained



Yes, this is WinForm related information, but like it or not, in the real world WinForms are still heavily used. Anyway, I dug how this showed off adding Coded UI testing to about any third party WinForm component...

Saturday, September 03, 2011

Okay WinForm/WPF Dialogs with Ookii.Dialogs - Ookii.Dialogs

"Ookii.Dialogs is a class library for .Net applications providing several common dialogs. Included are classes for task dialogs, credential dialogs, progress dialogs, input dialogs, and common file dialogs.

This package contains two class libraries: Ookii.Dialogs.dll for use with Windows Forms, and Ookii.Dialogs.Wpf.dll for use with Windows Presentation Foundation. The classes inside are pretty much identical; only the input dialog is not available for WPF. Some additional utility classes for Windows Forms are provided that are not available for WPF, see below for details.

The included sample applications Ookii.Dialogs.Sample.exe and Ookii.Dialogs.Sample.Wpf.exe demonstrate the dialogs for Windows Forms and WPF respectively. View the source of these applications to see how to use the dialogs.

Full reference documentation for the class library is available in the online and in the help file included with the download.


This is a pretty cool looking collection of Winform/WPF dialogs, a library that I've not seen before. I doesn't look like it's been updated in a couple years, but the source is provided and the license looks very friendly, so have at it!

Here's some snaps of the mentioned sample app.




(via - rtaylornc)

Sunday, July 31, 2011

WinForm HTML Editor Control - Adding HTML editing to your WinForm app is drag and drop away...

Carl's Blog - WinForms HTML Editor

"A few years ago I wrote a WinForms HTML Editor. As I have been working in WinForms again it seemed appropriate to post the code up to a new location:

The purpose of the Html Editor is to provide Html Editing capabilities within a WinForms control; satisfying the requirements of input for rich text layouts and simple portal type information. Examples of the former are case where the Rich Text control would normally be utilized; documentation, complex descriptions where text formatting is required, correspondences, bulletins, etc. Examples of the latter case are such items as dashboards; news clips, announcements, company references, etc. These are defined by cases where complex layouts are required that may include images and links.

The control emulates the operations that are available within a Rich Text control, but have information persisted and restored using an Html BODY element.



MSDN Code Gallery - WinForms HTML Editor


High level design goals are:

  1. Provides robust WYSIWYG editing capabilities whose contents are persisted in HTML format.
  2. Is easily reusable in other projects.
  3. Provides methods for saving HTML files to and loading files from disk (with the appropriate security demands).

The basic operations of the control are thus defined as:

Standard Text Editing

  1. Support basic formatting commands such as Bold, Italic, Underline, Strikeout, Font Name, Font Size, Font Color, Justification (Left, Right, and Center), Bullets and Number Lists. Dialogs should be presented to the user for modifying Font and Color attributes.
  2. Provide for standard Cut, Copy, Paste, Undo, Redo, Select All, and commands.
  3. ...

Body Properties

  1. Have the ability to simply set the text of the document body, the inner text of an Html Document; a browsable designer property.
  2. Allow for the assignment of the complete Body element (Body outer Html), preserving and body properties. Also allow for the
    assignment of the Body contents, Body inner Html.
  3. ...

External Behavior

  1. Allow a reference to a stylesheet to be applied to the document at runtime. The purpose is to allow the definition of a corporate wide stylesheet that all documents should reference for standardizing fonts, colors, etc.
  2. Allow a reference to a script source file to be applied to the document at runtime. The purpose is to allow the use of a corporate script file that can be used for handling links requiring programmatic redirection.
  3. ...

HTML Editor Non Goals

The Html Editor is not designed to provide similar functionality to Html Editor Products. For complex layout requiring Styles, Absolute Positing, Frames, Multi-Media, etc, these products should be utilized.

Operations that the control does not support are thus defined as:

  1. Support is only included for a single Font selection and not Font Families.
  2. Support for 2D-Position, Absolute Position, and Live Resize is not included.
  3. Multiple Selections of items is not supported and all operations are based on a single selected control.
  4. Simple Font properties are used rather than style attributes. The inclusion of style attributes brings around complexity regarding the use of Span tags.
  5. There was the option to have the control be Tab driven; supporting Design, Edit Html, and Preview. This would then have made the control look more like a fully-functional Html editor rather than a replacement to the Rich Text Box.

Here is a complete set of documentation: Html Editor Application.pdf


This control (for which you get the source also) has a 30 page doc... Shiney!


Here's a snap of the source, control and sample app, in VS;


Tuesday, July 12, 2011

Interactive WinForm Tag Cloud Control (Think “Cool, I can add a Word/Tag Cloud thing to my WinForm app!”)

CodePlex - Word Cloud (Tag Cloud) Generator Control for .NET Windows.Forms in c#

“Generate word cloud form some input text. A word cloud is a set of randomly arranged set of words used in your text. The size and the color of each word expresses it's usage frequency. Rarely used words are small and pale. The control is clickable and allows to identify a word under mouse.



This control is inspired by the free web based word cloud generator called Wordle.

In fact the control is a screw-out product of my project at .

I really loved visualizations produced by Wordle, but my goal was to write a non web based local solution to process large amount of sensible data. There where number of components I found on the web, but most of them had either very pure performance when processing text and the visualization or layout was not that I expected.


CodePlex - Source Code Word Cloud Generator

“Brief Description

Generate word cloud form your code to see what your code is about and what it does. A word cloud is a set of randomly arranged keywords, variable and class names etc. used in your code. The size and the color of each word expresses it's usage frequency. Rarely used words are small and pale. It might give you a hint about how good or bad your code base is and how to improve it.


The idea behind this project is quite simple and comes form Phillip Calçado's blog post Tag Clouds: See How Noisy Your Code Is

A tag cloud (word cloud) is a visual representation for text data. Words are usually placed on some rectangular area and the importance of each tag is shown with font size and/or color. This format is useful for quickly perceiving the most prominent terms in analyzed text. Wordle is one of the free tools to build such clouds. You can paste any text or a website URL and in a few seconds you get an idea what the website or text is about. And what is your code about?

One more very interesting article about that can be found under in the book 97 Things Every Programmer Should Know.

So if you take your code remove comments, literals, block some very common words (like company name) and generate a word cloud of it, you will get an interesting picture to discuss with your colleagues in a coffee corner.

  • If words "if", "then", "else", "switch", "case" are first what you see - your code is sprinkled with conditionals!
  • Is "string" in your words top 10 ? - Congratulations if you write text processing software, otherwise in might be a bad smell.
  • Are you writing API or a library so you should see word "public" in front rows. If you are not working on a library or API, the word public might be a signal to think on better protection.
  • Do you see your classes at first glance or are they far away in background? Behind "int", "byte", "array" etc.? Is your code in your domain language? By the way very interesting article on this topic from the book 97 Things Every Programmer Should Know.

We have tried this with multiple projects code bases. Every time except interesting new facts we learned about our own code, it was pretty much fun comparing different code clouds with each other. But do not forget, it is not a replacement for static code analysis and even not a code metric calculator. "Like most visualisation tools it is not a scientific proof of any kind but it gives you a hint about how good or bad your code base is." ( Phillip Calçado)


I can see where something like this could be very useful for data analysis and exploration… hum…

Tuesday, May 17, 2011

Adding Coded UI Test support to Third Party WinForm Controls Series

Mathew Aniyan's Blog - Enabling UI Testing for Third party WinForms custom controls - 1 

“Most of the leading Third party WinForms custom control vendors implement Microsoft Active Accessibility(MSAA). Since Visual Studio UI Testing framework uses MSAA for WinForms controls, it is natural to expect that users can test these custom controls also. The custom control vendors have implemented sufficient accessibility for Narrator. There are some subtle differences in the requirements for Screen Narrator & UI Test Framework. In this article, I will describe the additional requirements from a Visual Studio UI Testing Framework perspective.

For the purposes of this article, I have picked up the DevExpress XtraScheduler Scheduler Control. The guidance in this article should be applicable for all custom WinForms controls.


Mathew Aniyan's Blog - Enabling UI Testing for Third party WinForms custom controls - 2

“In the previous article, I described how we can make the DevExpress Scheduler Control & Appointments visible to Visual Studio UI Testing Framework. In this article, I will describe how we can retrieve rich properties for both these controls. These properties can then be used for validation in Coded UI Test.

In order to achieve this, we need to implement a Property Provider extension for the Visual Studio UI Testing framework.


Given that I like to buy over build where possible, I thought this might be useful…

Wednesday, November 17, 2010

They can have your WinForms App when they pull if from your cold dead fingers? Don’t think WPF is “it” for you? Wish Microsoft would just ask you what’s keeping you from moving to WPF? Well they are! (asking that is)

10REM.NET (Pete Brown) - Windows Forms Developers: Tell me about your applications

“I want to help Windows Forms developers transition applications to Silverlight and WPF. To do that, it will help me to understand the types of applications that are being maintained or newly developed in winforms today.

Help me help you. Answer as many of the questions above as you can, in the comments below. This is going to lead into content (talks, videos, posts etc.) and perhaps even tooling and templates to help make the transition easier for you. …


I love seeing this kind of reaching out. They can’t help us/you move to WPF if then don’t know what’s keeping us/you from moving to WPF…

Friday, November 05, 2010

Using .Net to create a System Tray app for Windows 7 - One Man’s Practical Approach and Guide

Simple-Talk - Creating Tray Applications in .NET: A Practical Guide

“This article is intended to be of interest to you in two different ways. If you just wish a practical guide on creating a system tray, then head straight for the section ‘The Tray Application Framework’, but if you’re more interested in actually using the application that we provide to illustrate the article, then click on ‘The Tray Application Framework‘. If you enjoy, and learn best by, following the whole process of how a particular system tray application was designed and built, then read on!


Introducing HostSwitcher: A Tray App for Some of You

  • Requirements
  • Instrumenting Your Hosts File
  • Usage
  • Features
  • Host Details View
  • Running on Windows 7
  • Execution Has Its Privileges

The Tray Application Framework

  • The Secret of the Tray
  • The Master Controller of a Tray App: The NotifyIcon
  • Tailoring Your Program Entry Point: The ApplicationContext
  • Rounding Out the ApplicationContext
  • Customizing WinForm Connections
  • WPF Can Play, Too!

Ensuring Only One Instance Executes: Mutual Exclusion

  • Technique 1: Native .NET Support
  • Technique 2: The Process Table
  • Technique 3: The Mutex Primitive
  • Strengths and Weaknesses of Mutex Techniques

If you are a .NET developer, you will probably be used to creating several different types of application. You’ll be familiar with either WPF or WinForms as the primary technology for desktop applications with a graphical user interface (GUI). You may also have required a console application for special needs such as batch processing or automated workflow. Finally, for more advanced applications, you may have needed to create a Windows service application, a type that, technically, does not even have a user interface.

There is one interesting type remaining: the system tray application.

This type of application is a kind of hybrid: it acts like a service, in that it sits in the background until you give it focus, then it acts like a GUI, allowing you to interact with it like a WinForms or WPF application.

You can find quite a number of articles on tray applications, just as I did when I needed to create my first one. I hit two problems during my self-edification: first, I did not find any single article that had all the necessary details. I collected bits and pieces from several to achieve a useful and usable solution. Second, many of these articles provide a kludge disguised as a solution: it is workable but certainly not the best way to create a system tray application.

In this article I’ll describe: the best practice for creating a tray application, complete with a tray application framework in C# that you can put to immediate use.

Because I didn’t like being told by one source that tray applications could exist only in WinForms, but not WPF, I’ll show you how you may choose to use either WinForms, WPF or both together with this framework. For those WPF purists, it turns out that there are independently developed libraries created by industrious developers that allow you to create strictly a WPF solution.


When I first had the thought “I need a small application to manage my host routing” I had little notion of the nuances and trade-offs involved in creating a well-designed tray app. And, just like the oft-stated comment that “If one person has a question, probably many others in the audience do, too,” I believe that if one developer realizes “Oh, that’s how it is done,” then there are probably many other developers who may appreciate the knowledge as well.


It’s been a while since I‘ve seen a good walk-through/guide/example/etc of creating a System Tray based app…

Monday, October 11, 2010

Windows Ribbon for WinForms v2.5 Released - Event handling reworked

Arik Poznanski's Blog - Windows Ribbon for WinForms v2.5 Released – New Events Mechanism

“The Windows Ribbon for WinForms is a managed wrapper around Windows Ribbon Framework, a free ribbon control that Microsoft provides in Windows 7 and Vista.
More details on this project can be found in the project site: .

I’ve just released another update to the project.

Note: this release contains breaking changes, only take it if you are starting a new project, or you don’t mind the needed updates to your code.

Basically I’ve changed how events are exposed in the library, made it a little more .NET friendly.

The benefits of these changes are:

  • You now get the control which generated the event as the sender of the event.
    For example, this allows registering the same callback function to different buttons and have the ability to know which button raised the event.
  • You can now use the Windows Ribbon for WinForms library in languages that can work only with proper .NET event handlers. The first request for this feature was from someone who wanted to use it in Progress ABL… There is a world beyond C#, C++ and VB.NET…


The new event signatures are much more “.Net” like… I like that.


Related Past Post XRef:
Windows Ribbon for WinForms v2.1 – Now with Visual Basic samples and number of new series entries too
Windows 7 Ribbon for WinForms – Yes you can…

Wednesday, April 14, 2010

Windows Ribbon for WinForms v2.1 – Now with Visual Basic samples and number of new series entries too

Arik Poznanski's Blog - Windows Ribbon Framework - Visual Basic .NET Samples

“Since so many people asked, I’ve created a Visual Basic .NET version of the Windows Ribbon for WinForms samples using Instant VB by Tangible Software Solutions.


Windows Ribbon for WinForms - RibbonLib (v2.1)

source code, 1105K, uploaded Today -

RibbonLib, version 2.1
A .NET library for using Windows Ribbon in WinForms applications

Note: you must have the Windows 7 SDK installed in order to compile the project.

C# and Vb.NET Sample applications included:

  • 01 - AddingRibbonSupport - Empty WinForms application with basic Ribbon support.
  • 02 - ApplicationMenuButton - WinForms application with Ribbon that contains an application menu with some buttons.
  • 03 - MenuDropDown - WinForms application with DropDownButton and SplitButton inside an application menu.
  • 04 - TabGroupHelp - WinForms application that uses Tabs, Groups and HelpButton.
  • 05 - Spinner - WinForms application that demonstrates the use of a Spinner control in the ribbon.
  • 06 - ComboBox - WinForms application that demonstrates the use of a CombBox control in the ribbon.
  • 07 - RibbonColor - WinForms application that shows how to change the ribbon global colors.
  • 08 - Images - WinForms application that shows how to work set images dynamically in the ribbon.
  • 09 - Galleries - WinForms application thats uses DropDownGallery, SplitButtonGallery and InRibbonGallery.
  • 10 - CheckBox - WinForms application that uses CheckBox and ToggleButton control in the ribbon.
  • 11 - DropDownColorPicker - WinForms application that demonstrates the use of a DropDownColorPicker control in the ribbon.
  • 12 - FontControl - WinForms application that demonstrates the use of a FontControl control in the ribbon.
  • 13 - ApplicationModes - WinForms application that demonstrates the use of ApplicationModes.
  • 14 - ContextualTabs - WinForms application that demonstrates the use of ContextualTabs.
  • 15 - ContextPopup - WinForms application that demonstrates the use of ribbon context popups.
  • 16 - RecentItems - WinForms application that demonstrates the use of ribbon recent items.
  • 17 - QuickAccessToolbar WinForms application that demonstrates the use of quick access toolbar.
  • 18 - SizeDefinition WinForms application that demonstrates the use of custom layout templates.


Since I first blogged about this very cool series, Windows 7 Ribbon for WinForms – Yes you can…), not only have there been a number of new entries added (see below) but the latest drop now VB samples too!  :)

Arik Poznanski's Blog - Windows Ribbon for WinForms, Part 0 – Table of Contents

Windows Ribbon for WinForms, Part 16 – ApplicationModes: How to work with ribbon application modes.
Windows Ribbon for WinForms, Part 17 – ContextualTabs: How to work with ribbon contextual tabs.
Windows Ribbon for WinForms, Part 18 – ContextPopup: How to work with ribbon context popup.
Windows Ribbon for WinForms, Part 19 – RecentItems: How to work with ribbon recent items control.
Windows Ribbon for WinForms, Part 20 – QuickAccessToolbar: How to work with the ribbon quick access toolbar.
Windows Ribbon for WinForms, Part 21 – SizeDefinition: How to define custom size definitions for ribbon group elements.


Related Past Post XRef:
Windows 7 Ribbon for WinForms – Yes you can…

Tuesday, April 13, 2010

Microsoft InteropForms Toolkit 2.1 - .Net’ing in a VB6 world

Microsoft Downloads - Microsoft InteropForms Toolkit 2.1

“Allows developers to incorporate VB.NET WinForms into their VB6 applications.

Version: 2.1
Date Published: 4/12/2010
Language: English
Download Size: 369 KB - 3.5 MB*

This toolkit helps you bring the power of .NET to your existing VB6 applications, by allowing them to display .NET Forms and Controls from within the same application. Instead of upgrading the entire code base, these applications can now be extended one form at a time. The goal is a phased upgrade, with production releases at the end of each iteration containing both VB6 and VB.NET forms running in the same VB6 .exe process.


You’d like to think VB6 is behind us, wouldn’t you? Well the real world is an uglier place than any of us would like imagine… Believe me, I’m staring at some production VB6 code as I write this (sigh…)

While we all want to move to the latest and greatest, when your legacy code is helping keep the lights on, it’s a hard call to throw it out.

VB6 still has some legs and will be around yet for a few more years, yet that doesn’t mean we’re locked away from taking advantage of the goodness than is .Net. Case in point, the Microsoft InteropForms Toolkit…


Related Past Post XRef:
Deploying a VB6 App when using the Interop Forms Toolkit
Microsoft Interop Forms Toolkit Rev'ed to 2.0

Monday, March 29, 2010

Looking for a little help moving from WinForms to WPF? How about a “toolbox-centric” Quick Reference Guide?

simple-talk - From WinForm to WPF: A Quick Reference Guide

“Like many of you, I have been an avid .NET developer / designer for some time, and have been eagerly awaiting both the new design tools of Visual Studio 2010 and the new capabilities of the .NET framework version 4.0 release. At the same time I decided to take the leap from WinForm to Windows Presentation Foundation (WPF) to take advantage of the expressiveness of the technology, and the richness of XAML. WPF is huge, so getting a clear understanding of either of these moves would be daunting; doing both together might seem well nigh overwhelming!

This article is not a starting point for the complete WPF neophyte. If that describes you, you will find this useful only in conjunction with other introductory WPF material. Rather, this article provides explanatory notes to my quick reference chart that could be quite a timesaver as you migrate from Visual Studio 2008 to 2010 and from WinForm to WPF. 

From WinForm to WPF A Quick Reference Guide


Here’s a snap of it;


And a close-up…


I need all the help I can get… ;)

(via Notes from a dark corner - WinForms to WPF Quick reference guide)

Saturday, February 06, 2010

Spell check enable your WinForm TextBoxes/RichTextBoxes via a nHunspell based IExtenderProvider

CodeProject - NHunspellTextBoxExtender - A Spellchecking IExtenderProvider for TextBoxes using Hunspell for .NET



With many applications, spell checking can be a vital aspect to include. Most people are used to the spell checking capabilities of products like Microsoft Word or OpenOffice. There are products available for purchase that can add spell checking capability, such as SharpSpell that can cost hundreds of dollars. But, there is a lack of Open Source, freely available tools that can provide the functionality of Microsoft Word. That is why I began to work on a spell checking IExtenderProvider that could extend any control that inherits TextBoxBase (both TextBox and RichTextBox inherit TextBoxBase).


… I wanted to provide spell checking capability to my GUI application. There were plenty of ways to spell check text, from using NetSpell, to programmatically using Microsoft Word's spell checker in a way similar to this article. Not every user could be assured to have Microsoft Word, and opening a new Word application can take some time and uses resources, so I wanted to stay away from that. I chose instead to use NHunspell. A useful article on it can be found at: hunspell-for-net.aspx.

I also wanted to provide a visual cue to the user that there was a spelling error. With RichTextBoxes, this could be done through simple underlining, such as in this article. My problem was that I had written a lot of code using simple textboxes, and I didn't want to change all of them to RichTextBoxes. Instead, I wanted to use the IExtenderProvider to extend any textbox with spell checking capabilities. To be honest, I had no clue where to even begin to do that. That is, until I found this blog that describes exactly how to draw that wavy red line on a textbox. With that base code, I was able to use NHunspell to determine where to draw the line.

Exploring the code

IExtenderProviders can be very useful, and most of us that code use them regularly, maybe even without knowing it. The simplest example is the ToolTip. When you add a ToolTip to a form, it doesn't show up as a control directly on the form. And, while it has its own properties, it also adds

image …”

I thought the number of things that this article brings together was pretty cool. That and the fact that it’s VB… :)


Related Past Post XRef:
NHunspell - 0.9.2 released and two cool C# & VB.Net Code Projects too
Hunspell (Open Office’s Spell Checker) wrapped for .Net = NHunspell – Your LGPL spell checker, hyphenation library for .Net