470,632 Members | 1,889 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,632 developers. It's quick & easy.

12 tables on aspx page: A performance hit?

Someone in my group created an aspx with 12 tables on it, each with several
rows in the table. In codebehind, we often make 1 or more tables visible /
invisible. (However within each table, there is no need to make individual
rows visible / invisible). I always believed that tables are much more
overhead than just having 1 table with lots of rows (Is that true?). So, I
suggested,

"Just have 1 table, and the <tr> 's we'll make invisible by putting
runat_server = true in the <tr> tags of that table". But there's 1 issue we
have with this, that maybe someone here can help me with:

If we have 1 table with 12 <tr>'s (instead of 12 tables), we still have
items within each <tr> that need to be arranged vertically. Like, 2
datagrids one on top of the other for example. I've seen sometimes that
<br> tags don't work in some browser resolutions / fonts: ie, those 2
datagrids that should be one-on-top of the other may appear on the same row,
unless you put in like, 5 <br> tags or more! Is there a way to avoid this
issue? If so, the 1 table + 12 <tr>'s will work.

OTOH, is there truly a significant performance hit by having 12 tables, vs 1
table with 12 rows, or is this just an old-wives tale and with .NET, it
doesn't make much difference either way? :)

TY Jason Shohet
Nov 18 '05 #1
1 1077
Hi Jason,

First, let me say that while tables can cause "slight" delays in page
rendering, it's not much. And, if the table is built correctly (widths are
specified and no contradictory instructions given), there will be virtually
no delay.

Having said that, you could turn on page tracing in .NET and see for
yourself with one page that has the tables and one that doesn't.

As for your <BR><BR><BR><BR> question/issue...You are right that adding
vertical spacing to a page/table is sometimes tricky, but this is an HTML
issue, not a .NET one. The best way to embed empty vertical space in a
table or page is to add:

<P>&nbsp;</P> wherever that space needs to be. No browser will ignore that.
If you plant that into a row of a table, you may find that clears up the
issue.

" Jason Shohet" <as****@hotmail.com> wrote in message
news:e4**************@TK2MSFTNGP11.phx.gbl...
Someone in my group created an aspx with 12 tables on it, each with several rows in the table. In codebehind, we often make 1 or more tables visible / invisible. (However within each table, there is no need to make individual rows visible / invisible). I always believed that tables are much more
overhead than just having 1 table with lots of rows (Is that true?). So, I suggested,

"Just have 1 table, and the <tr> 's we'll make invisible by putting
runat_server = true in the <tr> tags of that table". But there's 1 issue we have with this, that maybe someone here can help me with:

If we have 1 table with 12 <tr>'s (instead of 12 tables), we still have
items within each <tr> that need to be arranged vertically. Like, 2
datagrids one on top of the other for example. I've seen sometimes that
<br> tags don't work in some browser resolutions / fonts: ie, those 2
datagrids that should be one-on-top of the other may appear on the same row, unless you put in like, 5 <br> tags or more! Is there a way to avoid this
issue? If so, the 1 table + 12 <tr>'s will work.

OTOH, is there truly a significant performance hit by having 12 tables, vs 1 table with 12 rows, or is this just an old-wives tale and with .NET, it
doesn't make much difference either way? :)

TY Jason Shohet

Nov 18 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

8 posts views Thread by BlueBall | last post: by
1 post views Thread by Gaye Kruchten | last post: by
1 post views Thread by digitalego | last post: by
29 posts views Thread by John Rivers | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.