Solved

Form goes blurred on losing focus

Posted on 2006-06-19
2
257 Views
Last Modified: 2010-04-23
Help - my VB.net form goes "blurred" when performing a large if the user switches to another windows application

How do I avoid this as the form makes the program look like it has crashed  (after it goes blurred) until it finishes the active and appears correctly.

Thanks
0
Comment
Question by:rwallacej
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 43

Assisted Solution

by:TimCottee
TimCottee earned 250 total points
ID: 16932961
Hi rwallacej,

If the activity is a loop then you can use application.doevents inside the loop to allow the processor to be freed up during the cycles of the loop. This will allow the form to repaint. Alternatively you can start your activity on a seperate thread which will have a similar effect.

Tim Cottee
0
 
LVL 10

Accepted Solution

by:
ericwong27 earned 250 total points
ID: 16933131

The BackgroundWorker control (.NET Framework 2.0) gives you easy asynchronous capability with Windows Forms.

Sample code can be found at
http://msdn2.microsoft.com/en-us/library/ywkkz4s1.aspx

0

Featured Post

Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
VB.Net creating Contact in Outlook 1 98
.Net remove carriage returns, line feeds and tabbs 5 36
Best book for Internet security 4 54
VB Catch Statement in Event Viewer. 2 20
This tutorial demonstrates one way to create an application that runs without any Forms but still has a GUI presence via an Icon in the System Tray. The magic lies in Inheriting from the ApplicationContext Class and passing that to Application.Ru…
Well, all of us have seen the multiple EXCEL.EXE's in task manager that won't die even if you call the .close, .dispose methods. Try this method to kill any excels in memory. You can copy the kill function to create a check function and replace the …
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
Are you ready to implement Active Directory best practices without reading 300+ pages? You're in luck. In this webinar hosted by Skyport Systems, you gain insight into Microsoft's latest comprehensive guide, with tips on the best and easiest way…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question