Comment On I swear, it beeps for no reason ... just wait ...

Here's a snippet from a web project that Jake was lucky enough to inherit ... [expand full text]
« PrevPage 1Next »

RE: I swear, it beeps for no reason ... just wait ...

2004-08-23 15:53 • by mearls@hotmail.com (Michael Earls)
This is funny, but it's not entirely fair... post the body of the Beep() method. :)

re: I swear, it beeps for no reason ... just wait ...

2004-08-23 16:01 • by Mike
That's a built in vb.net function. Just tested it out and it does indeed make the server beep...

re: I swear, it beeps for no reason ... just wait ...

2004-08-23 16:14 • by Andy
Classic.... I'm sure this developer swears it works on his machine....
-Andy

re: I swear, it beeps for no reason ... just wait ...

2004-08-23 16:44 • by Hassan Voyeau
How do you generate a client side beep using ASP? I saw a java applet solution but I couldn't find anything related to asp :(

re: I swear, it beeps for no reason ... just wait ...

2004-08-23 17:10 • by Tim Cartwright
javascript alerts beep.

re: I swear, it beeps for no reason ... just wait ...

2004-08-23 20:12 • by blameMike
This tool probably runs IIS on his development machine. Naturally, the Beep function will invoke the desired response.

LMAO!

RE: I swear, it beeps for no reason ... just wait ...

2004-08-23 21:16 • by don@ghostdev.ca (Don Newman)
Maybe he had it in there for debugging purposes and never stripped it out? Or ... he could just be a schmuck. Let's be glad he didn't use a message box.

re: I swear, it beeps for no reason ... just wait ...

2004-08-23 23:26 • by The Wolf
If he used a message box the script would time out unless the admin clicked on it, haha!

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 01:28 • by nobody
i remember when i used to make mistakes like that all the time. The one that really got me was having a loop changing the contents of a label, and siting around waiting for the contents of the label to be updated on my screen. The good old days. That was nearly 10 years ago. Actually, just this week, I coded:

IDesignerHost host ....;
host.CreateComponent(typeof(Button));

and scrateched away 10% of my hair wondering why the button never appeared in the form on the designer surface. LMAO.

Have a nice day ...

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 02:54 • by Roger
well it _could_ be a custom beep function (not vb built in)

something like this:

sub Beep()
response.Write("<script lang=...")
response.Write("..whatevery you do in javascript to beep")
response.Write("</script>")
end sub


i do the same but for window navigation ,eg opening new windows via server code

//Roger

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 03:08 • by Hilton G
another question: why is he HtmlEncoding the QnumAs item?? Perhaps he is looking for CInt()?? ;-)

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 04:29 • by Ray S
Excellent, server-side beeps. I hope they have a volume control!

And finally a more useless usage of the Beep command than my submission ( http://TheDailyWTF.com/archive/2004/07/21/628.aspx ).

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 05:15 • by Tamer
Very funny, you can make a server beep evey time you have a new visitor or everytime you sell something over the web! so not entirley useless!!

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 07:04 • by MrGenericComment
A more reasonable explanation:

In this server room, there is a large microphone positioned next to the server. This microphone is attached to a GIANT DEATH ROBOT.

When the server beeps, the ROBOT is dispatched... it has your IP Address... soon it will have you...

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 08:37 • by Sean Schade

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 08:38 • by karpo
I made the sane mistake with a COM+ class once. I swear it worked quite perfect, locally!

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 08:38 • by karpo
same, not sane.

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 09:21 • by Sergio Pereira
This is a classical but sad example of a breed or programmers that know the syntax but don't understand squat about how the program runs.
As noted, the HtmlEncode is pretty intriguing... It must have Option Strict Off.

It all makes sense

2004-08-24 11:30 • by icelava
This application is a web-based test for students. Each time a student summits a blank answer, it will Beep() to inform the teacher. And s/he will taking approaching the guilty student with cane in hand.

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 11:32 • by Aarrgghh
The alert() thing is funny.

I wrote a Group Policy extension this spring. Those things are loaded by winlogon. Now, when you fail an ASSERT() in a debug build (of anything), it pops up a dialog, and sits there and blocks until somebody clicks on a button. However, it turns out that when winlogon shows a dialog, the user can't see the dialog until logging out (winlogon ought not to be *doing* that, anyway). So it *looked* like the poor GPx just sort of fell into a coma at some point, and then suddenly woke up and crashed later on.

You can imagine the hilarity that ensued before I realized what was happening. Thank God for remote debugging.

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 14:56 • by Patrick Sullivan
um while the Beep() is beautiful whatever happened to the requiredfieldvalidator?

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 15:37 • by me
to karpo : i agree with you. it's not sane by any means.

re: I swear, it beeps for no reason ... just wait ...

2004-08-24 18:19 • by Tim Cartwright
OK, I am an ex VB'er, and I find this code insane, but I would like to comment on another aspect of this code. VB.Net developers, learn short circuiting! PLEASE. His second if statement could be so much more effecient. Of course he may want it to work the way it does, but I don't have the spec.... ;-p

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbls7/html/vblrfvbspec11_10_1.asp

re: I swear, it beeps for no reason ... just wait ...

2004-08-25 05:53 • by MrGenericComment
Tim,

OrElse what?

re: I swear, it beeps for no reason ... just wait ...

2004-08-25 15:01 • by cc
cc

re: I swear, it beeps for no reason ... just wait ...

2004-08-25 15:19 • by Aarrgghh
Tim,

Seems to me that a language with non-short-circuiting boolean AND and OR by default is a WTF unto itself.

And if they're so damn smart, where's their short-circuiting boolean EXCLUSIVE OR, eh? EH? Let's see it! C'mon, I dare ya!

re: I swear, it beeps for no reason ... just wait ...

2004-08-25 15:50 • by Tim Cartwright
Problem was / is that there was a LOT of pre-existing VB6 code that would have been broken if MSFT had converted the logical operators to true short circuiting operators. Same thing with the whole base 0 thing. IMHO MSFT should have stuck to their guns, said that VB'ers would need to re-work their code (IT IS a <b>NEW</b> language anyway), and rewrite properly.... Sigh, OH well.....

re: I swear, it beeps for no reason ... just wait ...

2004-08-25 16:36 • by Aarrgghh
Tim: Actually, I'm with MS on that one. The chaos would be beyond belief and everybody would hate them (not just Slashdot).

I mean, it wasn't a general drastic cleanup of the language anyway, was it?

re: I swear, it beeps for no reason ... just wait ...

2004-08-26 14:32 • by Jake
About the messages boxes...

Just wait ;)

Jake

re: I swear, it beeps for no reason ... just wait ...

2004-08-31 14:46 • by DUH
I just don't get it. why doesn't beep() work?
LMAO

re: I swear, it beeps for no reason ... just wait ...

2004-09-08 17:44 • by xavier
actually use page.registerstartupscript to generate the beep function in javascript
same goes for messageboxes == alert
xavier

re: I swear, it beeps for no reason ... just wait ...

2004-09-24 13:48 • by Chris
Also, why didnt he use RequiredFieldValidation controls.... :o

*BEEP*

re: I swear, it beeps for no reason ... just wait ...

2004-09-27 06:31 • by M.
I've seen this before, but with a MessageBox instead of a beep. Honest.

Re: I swear, it beeps for no reason ... just wait ...

2008-02-12 09:27 • by Hal9000 (unregistered)
Err...

If lblError is a label control (which the name implies) then this code will work and will simply show an additional text field, in this case showing the error message, on the served web-page.

Just "In case you're not versed in ASP.NET" :)
« PrevPage 1Next »

Add Comment