473,738 Members | 5,084 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Arrays of Controls

Can .NET handle the old system of arrays for controls used in Visual Basic?
eg

TextBox(1), (2) ...

Nov 18 '05 #1
4 1245
You can certainly build an array of controls, .NET will support an
array of any type.

Getting support from the designer, on the othjer hand, is a different
matter.

--
Scott
http://www.OdeToCode.com

On Sun, 08 Aug 2004 09:42:53 GMT, "news" <sa***@logician s.com> wrote:
Can .NET handle the old system of arrays for controls used in Visual Basic?
eg

TextBox(1), (2) ...


Nov 18 '05 #2
You mean dynamic building of controls?

I was thinking of the old VB screens (eg VB 6) which had a SHIFT system and
PASTE. A array of controls was easily built and then a LOOP to set
attributes in an event.

I have looked at DataGrids, REpeaters, and DataLists but they seem to handle
one db column (last two controls) and the Grid is difficult to handle for
more advanced functions. I have built some controls using static controls
Text1, Text2 etc but this is not good code.

So what did MS replace the old arrays in VB with? They were widely used.
"Scott Allen" <bitmask@[nospam].fred.net> wrote in message
news:2r******** *************** *********@4ax.c om...
You can certainly build an array of controls, .NET will support an
array of any type.

Getting support from the designer, on the othjer hand, is a different
matter.

--
Scott
http://www.OdeToCode.com

On Sun, 08 Aug 2004 09:42:53 GMT, "news" <sa***@logician s.com> wrote:
Can .NET handle the old system of arrays for controls used in Visual Basic?eg

TextBox(1), (2) ...

Nov 18 '05 #3
AFAIK, the control arrays known to VB did not make it to the .NET
world (see
http://msdn.microsoft.com/chats/vstu...io_042302.asp).

You might want to take a look at the repeater again. It can handle
multiple columns (or did you mean to say one row?). All the data bound
controls can then be found in the Controls array it biulds.

--
Scott
http://www.OdeToCode.com

On Sun, 08 Aug 2004 16:09:00 GMT, "news" <sa***@logician s.com> wrote:
You mean dynamic building of controls?

I was thinking of the old VB screens (eg VB 6) which had a SHIFT system and
PASTE. A array of controls was easily built and then a LOOP to set
attributes in an event.

I have looked at DataGrids, REpeaters, and DataLists but they seem to handle
one db column (last two controls) and the Grid is difficult to handle for
more advanced functions. I have built some controls using static controls
Text1, Text2 etc but this is not good code.

So what did MS replace the old arrays in VB with? They were widely used.
"Scott Allen" <bitmask@[nospam].fred.net> wrote in message
news:2r******* *************** **********@4ax. com...
You can certainly build an array of controls, .NET will support an
array of any type.

Getting support from the designer, on the othjer hand, is a different
matter.

--
Scott
http://www.OdeToCode.com

On Sun, 08 Aug 2004 09:42:53 GMT, "news" <sa***@logician s.com> wrote:
>Can .NET handle the old system of arrays for controls used in VisualBasic? >eg
>
>TextBox(1), (2) ...
>
>


Nov 18 '05 #4
No I did not mean to say one row.
"Scott Allen" <bitmask@[nospam].fred.net> wrote in message
news:0d******** *************** *********@4ax.c om...
AFAIK, the control arrays known to VB did not make it to the .NET
world (see
http://msdn.microsoft.com/chats/vstu...io_042302.asp).

You might want to take a look at the repeater again. It can handle
multiple columns (or did you mean to say one row?). All the data bound
controls can then be found in the Controls array it biulds.

--
Scott
http://www.OdeToCode.com

On Sun, 08 Aug 2004 16:09:00 GMT, "news" <sa***@logician s.com> wrote:
You mean dynamic building of controls?

I was thinking of the old VB screens (eg VB 6) which had a SHIFT system andPASTE. A array of controls was easily built and then a LOOP to set
attributes in an event.

I have looked at DataGrids, REpeaters, and DataLists but they seem to handleone db column (last two controls) and the Grid is difficult to handle for
more advanced functions. I have built some controls using static controls
Text1, Text2 etc but this is not good code.

So what did MS replace the old arrays in VB with? They were widely used.
"Scott Allen" <bitmask@[nospam].fred.net> wrote in message
news:2r******* *************** **********@4ax. com...
You can certainly build an array of controls, .NET will support an
array of any type.

Getting support from the designer, on the othjer hand, is a different
matter.

--
Scott
http://www.OdeToCode.com

On Sun, 08 Aug 2004 09:42:53 GMT, "news" <sa***@logician s.com> wrote:

>Can .NET handle the old system of arrays for controls used in Visual

Basic?
>eg
>
>TextBox(1), (2) ...
>
>

Nov 18 '05 #5

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

Similar topics

1
2170
by: James Bond | last post by:
I am a very new VB.Net programmer (I was low intermediate in VB6) working on a small app where I need to manipulate a bunch of related text boxes. In VB6 I would have created a control array and done something like this: For X = 0 to 9 'do whatever to TextBox(x) Next x Since control arrays are no longer supported, I was wondering what would
3
6404
by: Christopher | last post by:
Hi I need to know how to work with a control array in c#. I would like to clear the contents of a textbox array after adding up the values in the textboxes. This is really easy in VB6 - im sure it easy in C# aswell - i just need the syntax. Thanks in anticipation Christopher
9
1828
by: Peter Krikelis | last post by:
Hi, Finally figured events and delegates whew! Thanks to the people in this community that helped me out. So now I have a class that raises an event. Now if I instantiate an object array of that class, and the event fires, is there any way of getting the array index of the object that raised that event?
13
1591
by: Bernie | last post by:
Sorry, but this ia another whine about VB.Net's lack of Control Arrays. I am new to VB.Net and I'm building an application that uses variable number of Label controls that are created at run time. The number of label controls will vary between 50 and 200. I have created an array of labels and placed them on the form. It works great, BUT I have not been able to raise any events for these controls. I made a small demo with 9 labels...
2
2252
by: John | last post by:
Hello everyone, I'm currently writing a program to keep track of schedule changes at a school. The goal is to have someone using the program to declare changes, then the program writes a html file, which is uploaded to a webserver. Then students and teachers can view it online, but there are also a couple of computers with 19" monitors standing around the school to display the webpage (IE kiosk mode). The program has a form containing...
8
2322
by: Greg | last post by:
In VB6 I made heavy use of control arrays I see they have been 'deprecated' in vb.Net, with a questionable explanation that they are no longer necessary which just addresses the event issue! Problem is I commonly associated several other controls with the same index inside the event handler - eg a Directory listbox, Label, Checkbox, Textbox Drivebox etc all associated with identical index. Now I see Control arrays belong to VB6...
5
1369
by: Diarmuid | last post by:
Are there control arrays in vb.net 2005? Maybe some one could help me out with an example. I know how to this in VB6. My database is called Planner.mdb There is a table called Weekdays. I want to read the first record in, and use that to set my labels as follows me.lblDay1 = WeekDays!Day1 me.lblDay2 = WeekDays!Day2 and so on. In VB6 I would have done this in a for loop. Something like me.lblDays(iLoop_ = rsWeekdays("Day" & iLoop)
3
1312
by: Robert Boudra | last post by:
I remember when VB.net came out that a couple of the seminars I went to mentioned that Control Arrays were going away and that there was a new and better way to execute the same code when an event occurs in one of a group of similar controls. Unfortunately, that was several years ago, and I don't remember how to do this. Can someone refresh my memory? Bob
5
324
by: Brian Shafer | last post by:
Hi, I loved being about to use control arrays in vb classic. Doesn't look like i can do this in vb.net? Any input?
0
8968
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8787
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9334
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9259
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
6053
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4569
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4824
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3279
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2744
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.