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

SuspendLayout Not Suspending...

I have a user control (tag) made up up 9 smaller user controls (minitag).

I have a panel on a form that is being populated with 81 of the tag controls in a grid configuration.

Even though I am using Suspend Layout, I still see the controls getting drawn as they are added to the panel.

I've tried suspending the layout of the form, of the panel and even on the user controls.

How can I get this thing populated wihtout seeing it being drawn so slowly on the screen?

Thanks.

J
Mar 26 '07 #1
5 7629
<rl*****@newsgroups.nospamwrote in message
news:ez**************@TK2MSFTNGP02.phx.gbl...
Even though I am using Suspend Layout, I still see the
controls getting drawn as they are added to the panel.
I've tried suspending the layout of the form, of the panel
and even on the user controls.
How can I get this thing populated wihtout seeing it being
drawn so slowly on the screen?
If you are using version 2 of the Framework, you can set to true the
property DoubleBuffered of the Form or Panel.
Mar 26 '07 #2
DoubleBuffered reduces the flickering, but it has not effect on the controls
being drawn slowly.
"Alberto Poblacion" <ea******************************@poblacion.orgwro te
in message news:%2****************@TK2MSFTNGP06.phx.gbl...
<rl*****@newsgroups.nospamwrote in message
news:ez**************@TK2MSFTNGP02.phx.gbl...
>Even though I am using Suspend Layout, I still see the
controls getting drawn as they are added to the panel.
I've tried suspending the layout of the form, of the panel
and even on the user controls.
>How can I get this thing populated wihtout seeing it being
drawn so slowly on the screen?

If you are using version 2 of the Framework, you can set to true the
property DoubleBuffered of the Form or Panel.


Mar 26 '07 #3
Hi,

I am sorry that I could not understand your scenario exactly.

What's the kind of your application, a WinForms or Web application?
I have a user control (tag) made up up 9 smaller user controls (minitag).
I have a panel on a form that is being populated with 81 of the tag
controls in a grid configuration.

What's the "tag controls" in the above sentence?

If possible, could you please send me a sample project that could just
demonstrate your problem? To get my actual email address, remove 'online'
from my displayed email address.

Only if I understand your problem exactly, I may provide possible
assistance to you.

Thank you for your understanding and cooperation!

Sincerely,
Linda Liu
Microsoft Online Community Support

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
==================================================

This posting is provided "AS IS" with no warranties, and confers no rights.

Mar 26 '07 #4
Linda,

It's a WinForm application. And the "Tag" control is a user control within
my project.

Picture a 9 x9 grid of squares (I called them tags). Each square has a
small 3x3 grid of mini tags within it.

I'm using 3 types of user controls to create each "tag". A "minitag", a
"minitagpanel" which is made up of 9 minitags. And a "tag" which contains a
minitagpanel. Then I add 81 "tags" to the controls collection of the panel
on the form. There's also some custom graphics getting drawn on the panel
behind the user controls.

I guess I just need to know the best way to handle the drawing, etc.
because it's all really slow.

I can send you the project if this is not enough info.

J
"Linda Liu [MSFT]" <v-****@online.microsoft.comwrote in message
news:yT**************@TK2MSFTNGHUB02.phx.gbl...
Hi,

I am sorry that I could not understand your scenario exactly.

What's the kind of your application, a WinForms or Web application?
>I have a user control (tag) made up up 9 smaller user controls (minitag).
I have a panel on a form that is being populated with 81 of the tag
controls in a grid configuration.

What's the "tag controls" in the above sentence?

If possible, could you please send me a sample project that could just
demonstrate your problem? To get my actual email address, remove 'online'
from my displayed email address.

Only if I understand your problem exactly, I may provide possible
assistance to you.

Thank you for your understanding and cooperation!

Sincerely,
Linda Liu
Microsoft Online Community Support

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
==================================================

This posting is provided "AS IS" with no warranties, and confers no
rights.

Mar 26 '07 #5
Hi J,

Thank you for your prompt response.

I understand your problem now. However, I'd like your sample project to see
how slow the usercontrols are drawn on the form. Could you please send it
to me?

Remove 'online' from my displayed email address to get my actual email
address.

Thanks!

Sincerely,
Linda Liu
Microsoft Online Community Support

Mar 27 '07 #6

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

Similar topics

0
by: Brent McIntyre | last post by:
Good evening all, I am having a little (HUGE ACTUALLY) problem using the SuspendLayout & ResumeLayout functions from a module. DELEGATE PROBLEM This is the code from the Module_Data:...
11
by: Jeffrey Hiess | last post by:
Something like getchar() doesn't work, since it "waits" for input. #include <stdio.h> while (1) { if (getchar()) /* break if any key is pressed */ { break; }
0
by: Owen Woo | last post by:
By Microsoft.Win32.PowerModeChangedEventHandler my application can only receive suspending event. But how can I prevent from suspending?
1
by: 2G | last post by:
Hi, I've a usercontrol that fills a listview with data from my db, I had this.SuspendLayout() in the beginning and this.ResumeLayout at the end of the function that loads the data and all worked...
6
by: Brent McIntyre | last post by:
Good afternoon all, I am having a little problem using the SuspendLayout & ResumeLayout functions from a module. This is the Delegate Declaration in the module: Public Delegate Sub...
0
by: Gwl | last post by:
I have a DataGridView and following code: private void button1_Click(object sender, EventArgs e) { dataGridView1.ColumnCount = 365; } When I click on the button it is extremely slow (some...
12
by: Dave | last post by:
Hi all, I have an application which has some worker threads which often have to stop and wait for some further information from other threads. These pauses will often take a long time (a couple...
5
by: Uzi | last post by:
Hi all, I have a thread which is running a long method in a third party component (witch is a com object and accessed via interop). I need to be able to suspend this thread. the...
1
by: =?Utf-8?B?RXRoYW4gU3RyYXVzcw==?= | last post by:
Hi, I was just about to wrap some code for filling a DataViewGrid in grid.SuspendLayout(); //Grid filling code grid.ResumeLayout(); when I got worried t hat something might go wrong in the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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.