473,395 Members | 1,656 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Flickering while refreshing

Hi,

I'm using a UserControl object for all the graphics handling in my
application. However, if I select an image and move it around, I get
flickering. So in order to get rid of the flickering, I added this code in
the constructor of the UserControl:

this.SetStyle(ControlStyles.AllPaintingInWmPaint |
ControlStyles.DoubleBuffer, true);

Now the control doesn't flicker, but I still get some minor flickering of
the image I am moving, and if I move the mouse too quickly, the image will
not "keep up" with the mouse pointer.

Any suggestions?
Nov 16 '05 #1
1 1883
how exactly are you moving that image around? If you are doing all
your painting to the Graphics object that comes through onpaint then
if your using doublebuffer and all painitng in paint you shouldn't get
any flicker at all. Are you instead using a second control and
painting on that perhaps?

Also, are you overriding OnPaintBackground?

Allen Anderson
http://www.glacialcomponents.com
mailto: allen@put my website url here.com

On Mon, 19 Apr 2004 12:43:21 -0400, "Jack Smash"
<so*****@somewebsite.com> wrote:
Hi,

I'm using a UserControl object for all the graphics handling in my
application. However, if I select an image and move it around, I get
flickering. So in order to get rid of the flickering, I added this code in
the constructor of the UserControl:

this.SetStyle(ControlStyles.AllPaintingInWmPain t |
ControlStyles.DoubleBuffer, true);

Now the control doesn't flicker, but I still get some minor flickering of
the image I am moving, and if I move the mouse too quickly, the image will
not "keep up" with the mouse pointer.

Any suggestions?


Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: BestNews | last post by:
Hi, I used an ActiveX control in C# client Application . I have created 'n' number of ActiveX controls on the UserControl. After user interaction some of the activeX control have to be refreshed...
3
by: Shoaib | last post by:
I have an IFRAME in HTML page whose source is set to some xml page.XML page gets displayed properly. But when i open some other IFRAME on top that IFRAME displaying xml, there is lot of flickering...
6
by: Joaquin Grech | last post by:
Hi I did alot of research on this on the web and msdn and I couldn't find anything. I have a listview showing as a grid (table looking, with rows and columns and no images at all, only text)....
2
by: John Lee | last post by:
Hi, I have a windows application that uses the listview to display about 50 items in detailed view - 4 columns. The first column is static and other columns will be updated in 100-1000ms - it...
2
by: John Lee | last post by:
Thanks Jay for your response. I tried your code and it still flickering a lot. To demonstrate it, you can grab a listview, create 3 columns - name, value, timestamp, in form_load event to add 50...
0
by: Praveen Balanagendra via .NET 247 | last post by:
Hi, I have many server control dropdown list in aspx page, on changing of one whole page gets refresh which causes lot of flickering..this looks odd. Is their any way to reduce flickering ...
5
by: n00b | last post by:
I have some forms with maybe around 30 controls on each and anytime I load these forms different parts of it start flickering though not all of them at once and not the same ones everytime. the...
6
by: Mark Thompson | last post by:
I have a problem with my Visual Basic .NET 2003 application which I have so far been unable to resolve. I am trying to get an OpenGL control that I have created working properly as a control on...
1
by: sj | last post by:
Flickering Subform! I am developing a Quotation system in Access 03. At entry, users enter data thru' a form with subform. However, the subform keep flicker when I run the system on computer...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.