Re: Conversion Problem
- From: "Ken Halter" <Ken_Halter@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 14 Jul 2008 08:44:01 -0700
"Armin Zingler" <az.nospam@xxxxxxxxxx> wrote in message
news:eNfhqu64IHA.2060@xxxxxxxxxxxxxxxxxxxxxxx
"Ken Halter" <Ken_Halter@xxxxxxxxxxxxxxxxxxxxxxxxx> schrieb
re-wrote VB basically from the ground up
Luckily they did. Finally got rid of all the hacks.
...talking about control arrays:
Why does a CommandButton have an Index (property) even if it does not
belong
to a "control array"?
Hopefully, you're not expecting an object to add/remove properties, just
because it may or may not be part of an array.
Or, create a control array of CommandButtons. Name it "Command1". Write
"MsgBox Command1.UBound". Put the caret on the word "Command1" and press
Ctrl+I. The IDE says: "Command1 As CommandButton". Huh?? The type of the
array is CommandButton, too? I thought that's the type name of a single
button. Where is that type declared? I don't find it in the object
browser.
I not even find "Ubound" anywhere in the object browser. Maybe I should
buy
new glasses.
You may be right about "time for new glasses". In *my* object browser, it
clearly states:
Class CommandButton
Member of VB
Or, try this in the immediate window:
? typename(command1(index))
CommandButton
?typename(command1)
Object
"Object"? Well...and what is the type of the object? It's probably
"VB-special-type-under-the-hood-and-nobody-will-ever-know"?
"Object" didn't make that much sense... with that, I agree... but, since
*everything* is supposedly an "Object" in dotNet, why does it surprise you?
What *really* suprises me is the fact they simply renamed "Variant" to
"Object" for dotNet.
Or, look at this, inside the Form:
Sub X(o As ???)
Msgbox o.
End Sub
umm... you're saying you have an IDE that excepts question marks as a Type?
Better re-install.
Sub Y()
MsgBox Command1.UBound 'supported by intellisense
X Command1 'Remember: it's an array!
End Sub
By what do the ??? have to be replaced in order to get the intellisense
list
(ubound, lbound, item, count) when typing "o." inside Sub X? What's the
type? Can you tell me?
Exactly what information are you looking for here? Intellisense doesn't work
when there are errors or missing libraries. Is that a surprise?
BTW, I don't need control arrays too because the main intentions a
programmer has can be achieved by means that did not even exist in VB6.
They
are:
- Create controls dynamically. "New CommandButton" does not work in VB6.
Pulllleeeezzzzz. Gimme a freaking break. You can create all the controls you
need, array or not, at runtime. The fact *you* don't know how isn't a fault
of the language.
"New Button" works well in VB today.
- Attach/remove handlers dynamically. No more being forced to have a
template control at design time because Add/Removehandler did not even
exist. Now being able to attach any handler of any event as long as
signatures match. (and, you can name the handler whatever you want)
Not impressed.
But I am fair. It's more work now if you have to attach the event of every
single control in the designer or in a loop to an event handler. However,
that's not a sufficient reason IMO as everything can still be done.
Keeping in mind that ".Net" was build from the ground up, there was no
need
to reintroduce control arrays - but maybe they will come back like these
horrible Form default instances that still make beginners think a class is
an object.....
You're exactly right. dotNet was built from the ground up. In fact, the
original VB team at microsoft wrote the first version of the CLR for use
with VB7 (the *real* VB6 upgrade) and later walked out on MS when the dotNet
team literally stole their project from them.
Since it was built from the ground up, why did they literally steal the
name? It's not VB. You said so yourself. It's "something else", but it's not
VB. As I've said probably 1000 times now, if they'd have been honest enough
to come up with a new name, absolutely none of this VB vs B# crap would be
taking place.
Hey, GoSub was so cool because we didn't have to pass arguments. Right.
Is that supposed to mean something? I haven't used Gosub since the 1980's...
how about you? Pass arguments? umm... what ever.
My Amstrad CPC464 back in 198? "booted" within one second. Was it
better?
I can see you're settling in and just accepting slow boot times. Good for
you. imo, it shouldn't take a quad-core CPU with 4 gigs of ram to boot in
less time than it takes to mow your lawn... But, if that's what you like,
have at it.
.
- Follow-Ups:
- Re: Conversion Problem
- From: Armin Zingler
- Re: Conversion Problem
- References:
- Conversion Problem
- From: John
- Re: Conversion Problem
- From: Patrice
- Re: Conversion Problem
- From: John
- Re: Conversion Problem
- From: Ken Halter
- Re: Conversion Problem
- From: Armin Zingler
- Conversion Problem
- Prev by Date: Flicker when updating Listbox
- Next by Date: Re: Off Topic Post - Reporting Services Question
- Previous by thread: Re: Conversion Problem
- Next by thread: Re: Conversion Problem
- Index(es):
Relevant Pages
|