473,325 Members | 2,480 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,325 software developers and data experts.

RE: Form rendering issue



"Ron" wrote:
Hi,

I have several windows forms in my project all which derive from a custom
form template. There is a lot of processing that goes on in the constructor
but I have kept the form_load event handler method free of any code.

My problem is that when I load the form it appears to draw incrementally
instead of just "snapping" up. I ideally would like to do all the rendering
of the form while it is hidden showing itself when the form has completely
finished rendering itself.

I have tried all sorts of trickery but I cant seem to prevent the form from
drawing itself before the users eyes which gives the application a sluggish
look, when it really isnt.

Thanks for any tips you might be able to offer.

Ron
Hi Ron,

I'm afraid you won't get the snappy user interface you may get with native
code. Event though you do all your creation in the constructor. A lot of
code won't actually run until the controls are actually created (assigned
with window handle etc). You are better off putting the loading code in the
load event rather than the constructor because of this.

There are things you can do to improve user experience. Especially for the
application startup. Use a splash screen if the loading takes a long time.
Hide complex usercontrols with a panel until everything is loaded. Use
DoubleBuffered. Cache data needed by the controls. Use asyncronous loading
of data.

--
Happy Coding!
Morten Wennevik [C# MVP]

Sep 12 '08 #1
0 1182

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

Similar topics

11
by: Jim | last post by:
Hi, I keep getting form results emailed to me that would indicate a form from my web site is getting submitted with all fields blank or empty, but my code should preventing users from proceeding...
2
by: Mark Hannon | last post by:
I am trying to wrap my brain around storing form elements inside variables & arrays before I move on to a more complicated project. I created this simple example to experiment and as far as I can...
6
by: Vaclav Jedlicka | last post by:
Hi all The code generated by the server side control asp:form generates invalid code. The HTML tag FORM always contains attribute "name". When I validate the page with the online validator...
4
by: Nacho Nachev | last post by:
Hello, AFIAK ASP.NET (1.1) uses a technology called 'Adpative Rendering' to output HTML that is compliant with the client browser or at least stick to HTML 4 specification or IE. This seems...
17
by: Jim Little | last post by:
Hello, I'm driving myself crazy either because I'm missing something about ASP.NET, or what I'm trying to do simply can't be done. First, I am not using session variables to track state. My...
2
by: Daniel | last post by:
Hey guys I have an app running a directx window, that part is fine but as you know it runs on an infinite loop redering frames per second. My issue is this is for a gaming app i am making that...
2
by: Spotnick | last post by:
I have no idea why, but since I'm trying to recreate my website using ASP.NET 2.0 I've encountered so many performance issues that I'm about to give up and continue using v1.1 Seriously, how can...
19
by: Coward 9 | last post by:
HI, I saw in an example hello.aspx, there is a <form tagbeing used like <form runat="server> I search all html tag references and could NOT find "runat" attributes for <formtag. which...
3
by: SAL | last post by:
Hello, I did google this issue and found some stuff related to BrowserCaps section of either web.config or machine.config but it didn't work. It seems that most pages in my webapp are okay but a...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.