• [email protected] (Michael Earls) (unregistered)

    This is funny, but it's not entirely fair... post the body of the Beep() method. :)

  • Mike (unregistered)

    That's a built in vb.net function. Just tested it out and it does indeed make the server beep...

  • Andy (unregistered)

    Classic.... I'm sure this developer swears it works on his machine....
    -Andy

  • Hassan Voyeau (unregistered)

    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 :(

  • Tim Cartwright (unregistered)

    javascript alerts beep.

  • blameMike (unregistered)

    This tool probably runs IIS on his development machine. Naturally, the Beep function will invoke the desired response.

    LMAO!

  • [email protected] (Don Newman) (unregistered)

    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.

  • The Wolf (unregistered)

    If he used a message box the script would time out unless the admin clicked on it, haha!

  • nobody (unregistered)

    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 ...

  • Roger (unregistered)

    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

  • Hilton G (unregistered)

    another question: why is he HtmlEncoding the QnumAs item?? Perhaps he is looking for CInt()?? ;-)

  • Ray S (unregistered)

    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 ).

  • Tamer (unregistered)

    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!!

  • MrGenericComment (unregistered)

    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...

  • karpo (unregistered)

    I made the sane mistake with a COM+ class once. I swear it worked quite perfect, locally!

  • karpo (unregistered)

    same, not sane.

  • Sergio Pereira (unregistered)

    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.

  • icelava (unregistered)

    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.

  • Aarrgghh (unregistered)

    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.

  • Patrick Sullivan (unregistered)

    um while the Beep() is beautiful whatever happened to the requiredfieldvalidator?

  • me (unregistered)

    to karpo : i agree with you. it's not sane by any means.

  • Tim Cartwright (unregistered)

    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

  • MrGenericComment (unregistered)

    Tim,

    OrElse what?

  • cc (unregistered)

    cc

  • Aarrgghh (unregistered)

    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!

  • Tim Cartwright (unregistered)

    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.....

  • Aarrgghh (unregistered)

    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?

  • Jake (unregistered)

    About the messages boxes...

    Just wait ;)

    Jake

  • DUH (unregistered)

    I just don't get it. why doesn't beep() work?
    LMAO

  • xavier (unregistered)

    actually use page.registerstartupscript to generate the beep function in javascript
    same goes for messageboxes == alert
    xavier

  • Chris (unregistered)

    Also, why didnt he use RequiredFieldValidation controls.... :o


    BEEP

  • M. (unregistered)

    I've seen this before, but with a MessageBox instead of a beep. Honest.

  • 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" :)

Leave a comment on “I swear, it beeps for no reason ... just wait ...”

Log In or post as a guest

Replying to comment #:

« Return to Article