To me, when you enumerate, you make a list of specific items, like
enumerating controls in a form. Am I missing something? I mean is there
something more to the meaning of the term "enumeratio n" or "enumerate" (in
programming context) other than just sounding technical. i.e. is it more
than just making a list of items? Are they the same thing? Please excuse my
'dah' factor, but it is really bugging me.
Willam Roberts
Joy to the world 5 2828
> To me, when you enumerate, you make a list of specific items, like enumerating controls in a form. Am I missing something? I mean is there something more to the meaning of the term "enumeratio n" or "enumerate" (in programming context) other than just sounding technical. i.e. is it more than just making a list of items? Are they the same thing? Please excuse
my 'dah' factor, but it is really bugging me.
I don't agree with your opening sentence. To me, when you enumerate, you
**take an existing list** and go through it (i.e., count it) one line at a
time; you don't **make** the list. In VB, that definition broadens a little
bit. For example, you can enumerate the controls on a form using code
similar to this
Dim ctrl As Control
For Each ctrl In Controls
If ctrl.Name Like "My*" Then
Debug.Print ctrl.Name
End If
Next
What is happening here is that the For-Each statement is calling up the
controls contained in the Controls collection (which VB maintains
automatically for us), one at a time, looking to print out (in the Immediate
window) all those whose name starts with the letters "My".
Rick - MVP
"Rick Rothstein" <ri************ @NOSPAMcomcast. net> wrote in message
news:_c******** ************@co mcast.com... To me, when you enumerate, you make a list of specific items, like enumerating controls in a form. Am I missing something? I mean is there something more to the meaning of the term "enumeratio n" or "enumerate"
(in programming context) other than just sounding technical. i.e. is it more than just making a list of items? Are they the same thing? Please
excuse my 'dah' factor, but it is really bugging me. I don't agree with your opening sentence. To me, when you enumerate, you **take an existing list** and go through it (i.e., count it) one line at a time; you don't **make** the list. In VB, that definition broadens a
little bit. For example, you can enumerate the controls on a form using code similar to this
Dim ctrl As Control For Each ctrl In Controls If ctrl.Name Like "My*" Then Debug.Print ctrl.Name End If Next
What is happening here is that the For-Each statement is calling up the controls contained in the Controls collection (which VB maintains automatically for us), one at a time, looking to print out (in the
Immediate window) all those whose name starts with the letters "My".
Rick - MVP
So, enumureating does not mean making a list, rathers its going through one,
that makes sense!
Willam Roberts <Wi*********@ho tmail.com> schreef in berichtnieuws
pQ************* *****@nwrddc02. gnilink.net...
Hello Willam, To me, when you enumerate, you make a list of specific items, like enumerating controls in a form. Am I missing something?
No, and yes. "To enumerate" is nothing more than "to count". You don't
*make* a list, you just go thru an allready existing one (Like Rick allready
mentioned).
Ofcourse, sometimes that list is somewhat hidden to the programmer's eye,
and/or you enumerate some list to retrieve some specific data outof it
(which you maybe use to store in a user-viewable form).
For example : think about enumerating entries outof a directory (using
"dir(filema sk)" ). The list (directory-entries) is allready there, you just
retrieve them one-by-one, maybe storing (partial) results into a list- or
tree-view.
I mean is there something more to the meaning of the term "enumeratio n" or "enumerate" (in programming context) other than just sounding technical. i.e. is it more than just making a list of items? Are they the same thing? Please excuse
my 'dah' factor, but it is really bugging me.
You're excused. You do *not* want to know the number of questions I did say
"duh !" to when it was explained to me, and thereby the obviousness of it
became clear to me ( the world-famous 20-20 hindsight :-)
Regards,
Rudy Wieser
Thanks Rudy,
I appreciate your thoughts. You and Rick have helped me through one of my
weaknesses, i.e. at times I tend to make things over-complicated when I
strive to understand them.
Kind Regards,
William Roberts
"R.Wieser" <rw************ ***@xs4all.nl> wrote in message
news:3f******** *************** @dreader5.news. xs4all.nl... Willam Roberts <Wi*********@ho tmail.com> schreef in berichtnieuws pQ************* *****@nwrddc02. gnilink.net...
Hello Willam,
To me, when you enumerate, you make a list of specific items, like enumerating controls in a form. Am I missing something? No, and yes. "To enumerate" is nothing more than "to count". You don't *make* a list, you just go thru an allready existing one (Like Rick
allready mentioned).
Ofcourse, sometimes that list is somewhat hidden to the programmer's eye, and/or you enumerate some list to retrieve some specific data outof it (which you maybe use to store in a user-viewable form).
For example : think about enumerating entries outof a directory (using "dir(filema sk)" ). The list (directory-entries) is allready there, you
just retrieve them one-by-one, maybe storing (partial) results into a list- or tree-view.
I mean is there something more to the meaning of the term "enumeratio n" or "enumerate"
(in programming context) other than just sounding technical. i.e. is it more than just making a list of items? Are they the same thing? Please
excuse my 'dah' factor, but it is really bugging me. You're excused. You do *not* want to know the number of questions I did
say "duh !" to when it was explained to me, and thereby the obviousness of it became clear to me ( the world-famous 20-20 hindsight :-)
Regards, Rudy Wieser
Willam Roberts <Wi*********@ho tmail.com> schreef in berichtnieuws
l8************* ******@nwrddc01 .gnilink.net...
Hello William, Thanks Rudy,
I appreciate your thoughts. You and Rick have helped me through one of my weaknesses, i.e. at times I tend to make things over-complicated when I strive to understand them.
You're welcome :-)
Regards,
Rudy Wieser This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Max |
last post by:
Suppose I have a simple type which is enumeration
<xs:simpleType name="fontStyle">
<xs:restriction base="xs:string">
<xs:enumeration value="bold" />
<xs:enumeration value="italic" />
<xs:enumeration value="underlined" />
<xs:enumeration value="strikeout" />
</xs:restriction>
</xs:simpleType>
|
by: Antoine Junod |
last post by:
Hello,
I definitely have a problem to build a clean data structure. I would be
very happy if some of you could help me as well as in the past.
Here is my problem:
-> I have a list of keywords.
-> I would like to link each keyword with a string.
-> I should be able to access the string of a given keyword via that
keyword.
|
by: Sampson |
last post by:
I have a question about enumeration and how to populate them during
runtime.
I am using vb.net but will happily take any advice in c# as well.
Here is an example to help illustrate what I am after.
Create a class named “clsMyItems” and in that class place an enum.
Public Enum Items
Item1 = 0
Item2 = 1
Item3 = 2
|
by: Ben Finney |
last post by:
Antoon Pardon wrote:
> I just downloaded your enum module for python
> and played a bit with it. IMO some of the behaviour makes it less
> usefull.
Feedback is appreciated. I'm hoping to provide a "one obvious way" to
do enumerations in Python.
> >>> from enum import Enum
> >>> day = Enum('mon', 'tue', 'wed', 'thu', 'fri', 'sat', 'sun')
|
by: Nathan |
last post by:
I'd like to use an enumeration as a datasource for a drop-down box. Is there
a way to do this?
| |
by: Charlie |
last post by:
Hi:
How would I bind a list to an enumeration so that enumeration value becomes
list values and enumeration constants becomes list text? Do you loop
through enum and add manually or is there a way to databind like when using
a table as list backing store?
Thanks,
Charlie
|
by: stran |
last post by:
I'm trying to create a simple type that holds two different types. The first is IDREF and the second is an enumeration of string. When I generate a sample xml, I can enter any ID previously stated in the xml and validates correctly. When I try to use one of the enumeration in the drop down list, the xml will not validate.
When I validate the xml in xmlspy, i get the error message "IDREF 'endofprogam': referenced ID 'endofprogam' was not found."...
|
by: scotchfx |
last post by:
Is there any way of declaring an enumeration in a base class in such a way that it can be "overridden" in a derived class... for instance:
class Base{
public:
enum Enum { //empty };
}
class Derived : public Base{
|
by: Jan Sneeuwman |
last post by:
Hello,
I am working on a library in C++, and the library goes with a header file
with a trailing comma at the end of some enumeration. Like this:
enum Abc {
ENUM_ONE,
ENUM_TWO
ENUM_THREE,
#ifdef HAVE_SOMETHING
|
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...
|
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,...
| |
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...
|
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,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
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();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
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
| |