Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > How to create controls at runtime

Reply
Thread Tools

How to create controls at runtime

 
 
michele
Guest
Posts: n/a
 
      08-04-2004
Hi, i'm trying to create some htmlinputfile controls at runtime in my page,
based on a integer variable (for example 5)
This is simple for the html code, but i don't know how to manage them in the
codebehind file, i've tryed to put them all in an array

protected HtmlInputFile[] filesUp = new HtmlInputFile[total];

but this doesn't work, so i can't get a reference to the controls in the
code...
Please help me
Thanks,
Michele




 
Reply With Quote
 
 
 
 
Scott M.
Guest
Posts: n/a
 
      08-04-2004
Instead of trying to create that control as an array.

Create one at a time inside of a loop that goes [total] times.
You could then place each newly created control in an Array object.

"michele" <(E-Mail Removed)> wrote in message
news:cera07$7hv$(E-Mail Removed)...
> Hi, i'm trying to create some htmlinputfile controls at runtime in my

page,
> based on a integer variable (for example 5)
> This is simple for the html code, but i don't know how to manage them in

the
> codebehind file, i've tryed to put them all in an array
>
> protected HtmlInputFile[] filesUp = new HtmlInputFile[total];
>
> but this doesn't work, so i can't get a reference to the controls in the
> code...
> Please help me
> Thanks,
> Michele
>
>
>
>



 
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
How to create HTML controls a runtime Jaime Stuardo ASP .Net Web Controls 2 07-22-2005 05:11 PM
How to Create Web Controls using ASP.NET Controls ? msnews.microsoft.com ASP .Net 3 04-27-2005 08:39 PM
Create Datagrid Controls as runtime Big Dave ASP .Net 1 10-07-2004 07:05 PM
How to create controls at runtime michele ASP .Net 1 08-04-2004 07:28 PM



Advertisments