Click here to Skip to main content
16,022,417 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hii ,is it possible to avoid flcikering for transaparent form.When the form focus goes to another form this transaparent form flickers .is there any way toa void flcikering for transparnet forms...
Posted

1 solution

How do you mean flickering? Do you maybe have a simple code example?

Possible you could set the form visibility to false temporarily when losing focus. (or set it transparent completely)

How did you implement this? If you didn't do it in the right way/order it is very well possible that the repaint from losing the focus skips your code and therefore is showing the form without transparency effect.

Try this in the constructor:

C#
InitializeComponent();
this.SetStyle(
            ControlStyles.UserPaint |
            ControlStyles.AllPaintingInWmPaint |
            ControlStyles.DoubleBuffer, true);


Also, have a look at this:

Transparency Tutorial with C# - Part 3[^]


Good luck!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900