Hi Keith,
Well, I'm not sure but this does seem like a buggy feature these days. I had the problem with the background visible until Opacity = 1.
This article says TransparencyKey doesn't work if the system's color depth is greater than 24 bits:
http://support.microsoft.com/kb/822495
My system is set up for 32 bit color so that's probably my problem. It could be yours, too. I don't know why my older example would work for you.
Instead of using TransparencyKey, you could set the form's region. See this example:
http://www.vb-helper.com/howto_net_set_form_region.html
The attached example (which is in
VB 2008, because that's what I had handy) does this. The ellipse doesn't quite fit the image on the form because it is centered (see the BackgroundImageLayout property) and the ellipse doesn't quite go to the edges of the image. You can fiddle with that if you like to make it fit perfectly. Or you could just make the whole background part of the ellipse image be blue and let the region clip it instead of worrying about TransparencyKey.
Here's the key code:
Code:
' Set the form's region to an ellipse.
Private Sub dlgSplash_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
' Make a GraphicsPath to define the Region.
Dim path As New System.Drawing.Drawing2D.GraphicsPath()
path.AddEllipse(Me.ClientRectangle)
' Convert into a Region.
Dim rgn As New Region(path)
' Restrict the form to the region.
Me.Region = rgn
End Sub
I hope that helps.