Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Forms jump and jitter

Status
Not open for further replies.

Casbah

Programmer
May 18, 2004
31
0
0
IE
Hi guys,

I am developing a Windows Forms application in VB.net 2005, but I have also seen this problem with 2003.

Basically its an mdi application and when I open and close different forms I am getting serious amounts of jumping around while the form draws itself to the screen.

I have done a serious amount of work on this application and it looks and works great except for this problem, and it's a major problem! I cant deploy a program that is looking like this everytime you change forms. I have never had this problem with vb6. Ive searched high and low for a solution but never found anything.

Has anyone else had this problem? Any solutions?

Thanks
 
Firstly are you overriding the Paint Event, or are there a vast number of controls on your forms. Secondly you could try using the forms SuspendLayout and ResumeLayout. Suspend the layout as you instantiate and resumelayout at the end of form load.



Sweep
...if it works, you know the rest..
Always remember that Google is your friend

curse.gif
 
Hi thanks for your reply.

Some of the forms have a lot of controls, others only 5 or 6. I have tried the suspendlayout and resumelayout before and it made no difference at all. I dont override the paint event at all.

I have thought maybe it's something to do with my machine, but this is a fairly fast good machine im running on, and i have far more complex forms in some of my vb6 apps that load instantly.

I also thought maybe the CRL just can't keep up when it comes to drawing the controls on the page, but seeing as I cant seem to find anyone else with this problem I'm baffled!!
 
Use your task manager while the form loads and see if you get serious memory and cpu spikes. If you do, then you may have something spawning another process during the load. Try commenting everythign out of the load event and see if that helps.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top