Posted: Thu Sep 30, 2010 12:29 pm Post subject: [C#].NET - TransparencyKey and MouseMove
Hello,
I am trying to set up a form with an transparent client area. For this purpose I use the TransparenyKey attribute. But when the client area is transparent, the MouseMove event does not work anymore. So is there a way make the form transparent without losing MouseMove? I could use a global mouse hook which computes the screen coordinates into client coordinates, but i think there must be an easier way. _________________
Joined: 25 Jan 2006 Posts: 8585 Location: 127.0.0.1
Posted: Thu Sep 30, 2010 4:38 pm Post subject:
If you are looking to do some type of glassy effect or still have full proper control of the client area, you might want to take a look into DWM. Keep in mind it would require your application to be ran on Vista/Win7 then.
If you are looking to just adjust the transparency overall, then you might want to look into:
SetWindowLayerAttributes
UpdateLayeredWindow _________________
Thank you for your answers. I decided to use a timer which translates the coordinates to client coordinates. I know, that is not a nice solution, but it works perfectly for my purpose.
Project is finished: http://www.youtube.com/watch?v=4xlDMsVHRIw _________________
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum