In Windows Vista, all standard window borders are translucent with some sort of a glass distortion effect on whatever is under them. This glass effect can permeate other areas of the window–such as surrounding the address and search bars in Windows Explorer or the playback controls in Windows Media Player. What if I want to do this in my .NET Windows Forms application as well? Is anyone aware of some sort of API call that you can use to control the area of this effect?
Reshaping the “glass” in Windows Vista
apinettransparencywindows-vistawinforms
Related Topic
- C# – the difference between const and readonly in C#
- C# – Should ‘using’ directives be inside or outside the namespace
- C# – What are the correct version numbers for C#
- .net – the best algorithm for overriding GetHashCode
- C# – Proper use of the IDisposable interface
- C# – How to update the GUI from another thread
- C# – How to remedy “The breakpoint will not currently be hit. No symbols have been loaded for this document.” warning
Best Answer
You have to P/Invoke from dwmapi.dll
http://www.danielmoth.com/Blog/2006/06/vista-glass-in-c_17.html
However, this is not officially supported by Winforms, and the general consensus seems to be that the best way to get glass in a .NET application is to use WPF instead.