473,387 Members | 1,749 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,387 software developers and data experts.

Form load - flickering

Dear friends

My app load the startup form and all of its controls step by step and its
indeed not nice. Do somebody know how to hide the form until the painting is
finished?

Regards Able
Nov 20 '05 #1
1 2014
You might want to try enabling double buffering. This causes the control to
be drawn first to a memory buffer, then rapidly copied to video memory when
finished, and it can dramatically reduce flicker. The following code
snippet demonstrates how to switch double buffering on.

Public Sub EnableDoubleBuffering()
' Set the value of the double-buffering style bits to true.
Me.SetStyle(ControlStyles.DoubleBuffer _
Or ControlStyles.UserPaint _
Or ControlStyles.AllPaintingInWmPaint, _
True)
Me.UpdateStyles()
End Sub

For more information, see the following topic on MSDN

http://msdn.microsoft.com/library/de...us/cpref/html/
frlrfsystemwindowsformscontrolclasssetstyletopic.a sp

Hope this helps!

Matthew Stoecker
Visual Basic User Education Team

--------------------
| From: "Able" <ab**@epost.no>
| Newsgroups: microsoft.public.dotnet.languages.vb
| Subject: Form load - flickering
| Lines: 9
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| Message-ID: <qi******************@news4.e.nsc.no>
| NNTP-Posting-Host: 80.212.114.27
| X-Complaints-To: ne********@telenor.net
| NNTP-Posting-Date: Thu, 08 Jan 2004 00:07:02 MET
| X-Trace: news4.ulv.nextra.no 1073516822 80.212.114.27
| Date: Thu, 8 Jan 2004 00:07:00 +0100
| X-Received-Date: Thu, 08 Jan 2004 00:06:49 MET (news01.chello.no)
| Path:
cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GP08.phx.gbl!newsfeed00.su
l.t-online.de!t-online.de!newsfeed.freenet.de!fr.ip.ndsoftware.net !proxad.ne
t!195.70.164.134.MISMATCH!news.tdcnorge.no!news01. chello.no!newsfeed1.e.nsc.
no!nsc.no!nextra.com!news4.e.nsc.no.POSTED!53ab275 0!not-for-mail
| Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.languages.vb:170857
| X-Tomcat-NG: microsoft.public.dotnet.languages.vb
|
| Dear friends
|
| My app load the startup form and all of its controls step by step and its
| indeed not nice. Do somebody know how to hide the form until the painting
is
| finished?
|
| Regards Able
|
|
|

Nov 20 '05 #2

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

Similar topics

1
by: Terry | last post by:
I've seen several posts from people who have seen this flashing in TreeView's when resizing a form. I've noticed it in my app, but only in the child windows. For example, my main form has a...
2
by: Pascal | last post by:
bonjour/hello I have an application with several forms : form1 is loaded at first. Man makes some staff (filling text box, clicking radiobutton) in this window and then click nextbutton and so on...
2
by: Robert Smith | last post by:
Hello, I have a problem with a form loading a repainting. Because the form uses an office 2000 styles, when it paints it causes a lot of flickering. The standard advice is to set the following...
8
by: nirdeshonline | last post by:
Hi, I have added a simple listbox in windows form under c# 2.0. It contains a collection of approx 10 strings as list items. Now when i resize the form whole listbox flickers. Please tell me...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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
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,...
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,...

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.