473,787 Members | 2,881 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Intensive flickering

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 forms are each generally separated
into 2-3 different panels and they start flickering with no apparent pattern.
I've tried turning on double buffering, same thing, no improvements. I've
tested it on different computers with different specifications and have
gotten more or less the same result. My own PC is an Intel P4 3.0Ghz
HT-enabled, 1 GB DDRII RAM, NVIDIA 6600GT 128 MB DDR3 RAM, 160GB Western
Digital Caviar 7200RPM (irrelevant really) running Windows XP Pro SP2, So I
see no reason for such flickering.
Btw each of the panels has a background image (PNGs) and most of the buttons
also have images. Most labels use a transparent background.
Any ideas?
Mar 26 '06 #1
5 2352
What are you doing when this flickering is occuring? Modifying controls?
Running through a paint method? Changing a datasource?

- Mark
On Mon, 27 Mar 2006 06:44:19 +0800, n00b <n0**@discussio ns.microsoft.co m>
wrote:
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 forms are each generally
separated
into 2-3 different panels and they start flickering with no apparent
pattern.
I've tried turning on double buffering, same thing, no improvements. I've
tested it on different computers with different specifications and have
gotten more or less the same result. My own PC is an Intel P4 3.0Ghz
HT-enabled, 1 GB DDRII RAM, NVIDIA 6600GT 128 MB DDR3 RAM, 160GB Western
Digital Caviar 7200RPM (irrelevant really) running Windows XP Pro SP2,
So I
see no reason for such flickering.
Btw each of the panels has a background image (PNGs) and most of the
buttons
also have images. Most labels use a transparent background.
Any ideas?


Mar 27 '06 #2
Sorry for the late reply.
When the flickering is happening the code is doing nothing, the parts of the
form just continuosly flicker. I'm not doing any paint menthod other than the
ones that are specific to each control. As for modifying controls the only
modification I make at any time is just showing a given panel and hiding all
other extra ones. I'm not using a datasource for data either, on form load
some data is added to the approriate listboxes... manually in the code, and
this is done inside a BeginUpdate and EndUpdate.

"Mark Harris" wrote:
What are you doing when this flickering is occuring? Modifying controls?
Running through a paint method? Changing a datasource?

- Mark
On Mon, 27 Mar 2006 06:44:19 +0800, n00b <n0**@discussio ns.microsoft.co m>
wrote:
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 forms are each generally
separated
into 2-3 different panels and they start flickering with no apparent
pattern.
I've tried turning on double buffering, same thing, no improvements. I've
tested it on different computers with different specifications and have
gotten more or less the same result. My own PC is an Intel P4 3.0Ghz
HT-enabled, 1 GB DDRII RAM, NVIDIA 6600GT 128 MB DDR3 RAM, 160GB Western
Digital Caviar 7200RPM (irrelevant really) running Windows XP Pro SP2,
So I
see no reason for such flickering.
Btw each of the panels has a background image (PNGs) and most of the
buttons
also have images. Most labels use a transparent background.
Any ideas?


Mar 28 '06 #3
Are you calling your methods to hide and show controls from within any
paint methods?

Mar 28 '06 #4
I'm not calling any methods in any of the paint methods, just in the load
method of the form and the OnClick events of buttons. (Btw just for future
reference is it bad to call such methods in paint methods?, Thnx)

"Steven Nagy" wrote:
Are you calling your methods to hide and show controls from within any
paint methods?

Mar 28 '06 #5
Well you have to be careful not to get caught in an infinite loop where
in your paint method you are doing something that tells the control to
repaint itself, thus causing constant repainting and thus flickering,
which is why I asked.

You could investigate the SetStyle method of controls, which might
alleviate some flickering, but you can't access this method without
inheriting from the control.
So for example, your panels would actually be n00bPanels, which in turn
inherit from Panel, and give them a method called SetStyle() which
calls the Panel base SetStyle method. There are SetStyle enums that
will help with flickering, but I would say that there is something else
that really needs attention.

Are you using a layout manager per chance for all those controls? How
are the panels placed, are they docked or anchored?
Are you handling the resize events for anything?

its a hard one...

Mar 29 '06 #6

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

Similar topics

3
1967
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 if i move the IFRAME window or enter some text. Both IFRAME contains veery simple XML and HTML. Can anyone tell me cause of flickering?? Any attribute i need to set? Any tips?
6
8868
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). I get the information to display on the listview from the network and I add items often and stuff. But more than adding items, what worries me is the step of modifying items.
1
1910
by: Jack Smash | last post by:
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);
2
8615
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 looks awful when it's running - flickering too much!!! Anyone know how to solve this flickering problem? or how should I deal with this issue? I see some other C++ app can display more than 100 items without any flickering in such as speed. Can...
2
2530
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 items into that listview as Item1 - Item49, add a timer to your windows form, set the timer interval to 100 ms, in the event handler, add the code to update the value and timestamp Random r = new Random(); listView1.BeginUpdate();
8
16929
by: benben | last post by:
I created a form and overrided OnPaint, OnClick and OnResize methods. My OnPaint calls base.OnPaint then repaints the whole screen. The screen flickers a lot! It didn't happen when the app was written in C++. What is the general strategy to reduce screen flickering with C# Forms? Perhaps saving the screen as a bitmap and just bitblip when painted, and only change the bitmap when necessary? is it possible? ben
0
1128
by: none | last post by:
Hello I have created a realtime data intensive application in C++/CLI. Data streams into this application through a set of ActiveX controls. For example, each stock symbol will be assigned to one of these controls and the symbol will be updated through one of the events of these controls. Symbols and their corresponding data are displayed in a listview. Data is updated few times a second per symbol.
6
3639
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 my main form in my VB.NET application. It does work and render correctly but the problem is that there is an awful flickering that happens on most PCs I try it on. The flickering is reminiscent of the sort that you get on a TV when it is not tuned...
1
3474
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 using runtime. This problem don't happen on set that has full ver of Access. Any advise? Pls Help, I have pulled off so much hair on this.
0
9655
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10363
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10169
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9964
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6749
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5398
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5534
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4067
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2894
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.