- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
If we're going to be totally strict, controls that have .Visible = false will still be rendered to ViewState in case you want to re-visibleize them and preserve previous values. So, in a sense, they're still on the page. Kinda. OK, not really.
Admin
Really, you are a genius. Seriously.
dZ.
Admin
WTF? They seriously balked at the idea of having real short-circuit evaluation? This was something I was dreaming of, even since I touched VB (I still feel dirty)
That explains all I need to know about true VB Developers right there.
Admin
I usually speak french! The first time I saw in VB .NET:
"If CondA AndAlso CondB Then ... ",
with my understanding of english, I tought it means: "Test CondA condition AND ALSO test CondB condition"; this is not the definition of short-circuiting in my opinion. The operator should have been named:
If CondA AndIfThePrecedingConditionIsTrueTestTheNextOne CondB Then ...
They should have made And in VB .NET a short-circuiting operator, and change their migrating tools to translate old "And" in VB6 to something like "AndOld" (or it could be AndAlso) [8-|]
Admin
That would have been a better option in my opinion. They should add a MaybeIf statement, too.
Admin
The label control renders on the client as a SPAN tag... if you wanted to show and hide text on the client, a Label control is a often a better choice than embedding the text in a DIV control.
If you wanted to make the label dynamic on the client side, register a script in the Labels attributes. Using either the DIV or Label method requires that you make the item visible when the page renders, otherwise neither would show up in the client's page source.
Its tough to say which way is more correct that the other. It really comes down to the situation.
Admin
What gets me about things like this post is that people go to all sorts of pains to display or hide this information by using the same built in features
It boggles my mind as to how this guy, while using the .Visible property did not think about taking advantage of this property while designing his incredible method for hiding controls.
Admin
I was thinking of an AndMaybe
If (something AndMaybe somethingelse) Then
Admin
that's not magic, that's... Disney!
[quack]
Admin
All kinds of possibilities...
AndWhileYoureAtIt
AndDontForget
AndNowThatYouMentionIt
...
Admin
<FONT face="Courier New" size=2>And2 : bigger, faster!</FONT>
Admin
That would be "Really, you are a genus, serously". rght?
Admin
mayhaps (thisObject notWithstanding anotherThing) {
}
inanycase {
}
It's a cautious programming language.