473,325 Members | 2,442 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.

How to create controls at runtime

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


Nov 18 '05 #1
1 1122
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" <mi********@jumpy.it> wrote in message
news:ce**********@grillo.cs.interbusiness.it...
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

Nov 18 '05 #2

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

Similar topics

5
by: Patrick Marti | last post by:
I wish to create some LinkButtons in DotNet. Because I will do it in dependence of the entries in a database, I can not add them with the mouse to the form as usually. I can create them in the...
3
by: RSB | last post by:
Hi Every one Having tuff time creating web controls Dynamically. All i am trying to do is read a table and generate a list of ASP TEXT Box. So how do i create this Control dynamically and where...
2
by: Tom Jackson | last post by:
Can anyone please point me in the right direction. I want to create some simple controls (radio buttons) at runtime. The problem is that I don't know how many radio buttons I need or where they go...
1
by: Luc | last post by:
Hi, I have a TabControl and, at runtime, I need to add some tabpages. The problem is that each tabpage is similar to the others and contains several controls. If I do...
3
by: JohnR | last post by:
I have a form with a number of text boxes, comboboxes etc. What I would like to do is create an event handler for the "mouseenter" event for each of the controls whereby I display information...
6
by: TonyMast | last post by:
VB 2005 - XP Pro - Windows forms I'm trying to write a simple multiplication tables program for my little girl. How can I create 200 labels, 100 textboxes. Here is what I've tried so far...
2
by: Melisa | last post by:
Hi, How can i create bitmap of a window form with all its child controls without showing this form? 1. I am trying to create bitmap image of a window form. 2. I am creating a new instance of...
7
by: Matt | last post by:
Hi all, I'm trying to create a system where it reads a number of records from a database and then creates a row in the GUI that contains a single field from the database and a button that has a...
0
by: =?Utf-8?B?U2hhcm9u?= | last post by:
Hello Gurus, I need to create a Microsoft Visual Studio 2005 report at runtime. I wrote a C# window application, that holds a DataSet and several DataGridView controls. Each of the...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
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: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
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...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
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.