Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > How to dynamically create controls on the client

Reply
Thread Tools

How to dynamically create controls on the client

 
 
Luke Breuer
Guest
Posts: n/a
 
      07-12-2004
I am in charge of writing a criteria selection page for queries. There
is the potential for a hundred or even hundreds of fields. Since we
want to display a decent amount of controls/data for each field, this
would quickly eat up space if all the controls were generated at the
server and sent to the client. Currently we have a setup like this
that requires a 500 KB download - absolutely unacceptable.

I would like to know if it's "kosher" or even possible to send the
user a list of the fields, their datatypes, etc., along with a piece of
javascript that will create the controls on the client side. If it is
at all possible, I would like to encapsulate this functionality so the
code-behind can access something simple like an Items collection to see
all the controls that were added.

The reason I want all the controls loaded at once is that roundtrips to
the server would take an noticeable amount of time that would be nice
if it could avoided.

Thanks in advance,
Luke Breuer

 
Reply With Quote
 
 
 
 
kw
Guest
Posts: n/a
 
      07-12-2004
If you are going to go that route, you could also consider using a Windows
app. The 500k still has to be downloaded, but you should make sure it's
downloaded only once by specifying a js file that loads the control data.
Another solution would be to break the problem up; using a TabStrip that
either dynamically loads all the content (via ASP.NET) or just loads
references to a separate js file.

"Luke Breuer" <> wrote in message
news:ccucdn$...
> I am in charge of writing a criteria selection page for queries. There
> is the potential for a hundred or even hundreds of fields. Since we
> want to display a decent amount of controls/data for each field, this
> would quickly eat up space if all the controls were generated at the
> server and sent to the client. Currently we have a setup like this
> that requires a 500 KB download - absolutely unacceptable.
>
> I would like to know if it's "kosher" or even possible to send the
> user a list of the fields, their datatypes, etc., along with a piece of
> javascript that will create the controls on the client side. If it is
> at all possible, I would like to encapsulate this functionality so the
> code-behind can access something simple like an Items collection to see
> all the controls that were added.
>
> The reason I want all the controls loaded at once is that roundtrips to
> the server would take an noticeable amount of time that would be nice
> if it could avoided.
>
> Thanks in advance,
> Luke Breuer
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
Inserting Controls Dynamically - with Validators Also Added Dynamically Jeffrey Todd ASP .Net 1 06-02-2005 04:33 PM
SPECIAL --> HOW TO "Dynamically Create Controls in ASP.NET with Visual Basic .NET " ??? tommy ASP .Net 0 06-14-2004 01:06 PM
Dynamically create controls ? Steven Caliendo ASP .Net 3 12-22-2003 09:27 PM
How do I dynamically create user controls? David J. Berman ASP .Net 1 06-30-2003 07:24 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57