Every situation is unique, performance questions like these tend to be
slightly pointless (sorry). I'm not sure who's against web controls, my
guess is that they are doing very unique things (in which case asp.net as a
whole might not be well suited for there needs (although i even doubt this))
or they simply don't have much experience.
With performance, like most things, there's a law of diminishing return.
There are things you can spend minutes on to get huge gains (and you should
'cuz they are good practice)...what you are talking about will take you huge
time (maintenance and bugs) and gain your tiny performance gains (and you
shouldn't 'cuz its bad practice). Look at your own requirements if you need
an example. You could give yourself a headache by maintaining <%='s in 500
cells and gain 1/4 second per request. Or you could save yourself a lot of
trouble, create a solid caching strategy and gain 8 times that amount.
With performance, again like most things, things aren't black and white.
The extra performance you'll incur will save you $$$ in maintenance and
staff, which you could use to buy better hardware, which might cost you more
to host, but which might give you better uptime, which might.....
Karl
"Weston Weems" <an*******@discussions.microsoft.com> wrote in message
news:0d****************************@phx.gbl...
Hrmm... I've heard arguments both ways... basically people
against the webcontrol's argument was simply that you had
to account for creation and gc of all the webcontrols.
Say I had a datagrid with 5 columns and 100 records, there
is 500 labels in memory (at least at the time of binding
anyway)
I could see how that route could cause some trouble in
resource management.
Anyway, anyone else have any input?
-----Original Message-----
As far as asp.net goes, I wouldn't suggest using <%= %>
if you can accomplish it from codebehind, it breaks the
nice separation between code and html source. Compiled
code is faster, and like you said using <%= %> doesn't get
compiled until runtime, which takes a bit longer, but the
performance difference wouldn't be anything to cry home
about. As far as scalability, you'll want to stick with
codebehind.
--Michael
"Weston Weems" <an*******@discussions.microsoft.com>
wrote in message news:0b8601c48b8a$2d63a7f0
$a*******@phx.gbl... I currently populate my datagrids manually from a
codebehind and use webcontrols within the template columns (for check boxes and viewing pleasure eg labels)
For performance and scalability... would late binding
where I'd just have <%=myVar%> really be a better way of doing things?
I always had thought creating a webcontrol and populating from codebehind was more optimized becase it was pre-
compiled.
Thanks
Weston Weems
.