Click here to Skip to main content
15,881,852 members

The Weird and The Wonderful

   

The Weird and The Wonderful forum is a place to post Coding Horrors, Worst Practices, and the occasional flash of brilliance.

We all come across code that simply boggles the mind. Lazy kludges, embarrassing mistakes, horrid workarounds and developers just not quite getting it. And then somedays we come across - or write - the truly sublime.

Post your Best, your worst, and your most interesting. But please - no programming questions . This forum is purely for amusement and discussions on code snippets. All actual programming questions will be removed.

 
GeneralRe: Who cares? Pin
Stefan_Lang11-Aug-14 20:56
Stefan_Lang11-Aug-14 20:56 
GeneralRe: Who cares? Pin
ColborneGreg11-Aug-14 21:00
ColborneGreg11-Aug-14 21:00 
GeneralRe: Who cares? Pin
Stefan_Lang11-Aug-14 21:03
Stefan_Lang11-Aug-14 21:03 
GeneralRe: Who cares? Pin
ColborneGreg12-Aug-14 5:11
ColborneGreg12-Aug-14 5:11 
GeneralDebugging pain PinPopular
Dave Kreskowiak31-Jul-14 4:38
mveDave Kreskowiak31-Jul-14 4:38 
GeneralRe: Debugging pain Pin
ZurdoDev31-Jul-14 4:51
professionalZurdoDev31-Jul-14 4:51 
GeneralRe: Debugging pain Pin
Nguyen.H.H.Dang31-Jul-14 17:57
professionalNguyen.H.H.Dang31-Jul-14 17:57 
GeneralRe: Debugging pain Pin
MarkTJohnson1-Aug-14 6:45
professionalMarkTJohnson1-Aug-14 6:45 
We have an application that automates the running of other applications we have that take data feeds from clients and process them. Automation uses a command line to kick of the different processing programs.

All of the sudden the automation starts logging an error even though the processing completes successfully. I finally track down the location of the line that is recording the log message. The code in automation scans the log file of the processing program for the string "error" and reports if it finds it. I look through the log files of the processing programs and everything looks normal, no errors being reported. After several more reports of this problem I am looking at the log file again and I finally find the cause of the problem. The file services people who manage the automation process wanted more detailed logging, to include recording the command line parameters being used for each different run of the processing application.

One of those command line parameters is used to turn on and off message/error logging. The message sent to the log file for the logging switch said,

"Command Line Parameter to log errors"

WHOOPS! Blush | :O
Yes, I added that code.
GeneralFloorwise appplication PinPopular
Thanks787231-Jul-14 0:10
professionalThanks787231-Jul-14 0:10 
GeneralRe: Floorwise appplication Pin
Eddy Vluggen31-Jul-14 1:36
professionalEddy Vluggen31-Jul-14 1:36 
GeneralRe: Floorwise appplication Pin
Duncan Edwards Jones31-Jul-14 3:03
professionalDuncan Edwards Jones31-Jul-14 3:03 
GeneralRe: Floorwise appplication PinPopular
ZurdoDev31-Jul-14 4:05
professionalZurdoDev31-Jul-14 4:05 
GeneralRe: Floorwise appplication Pin
Richard Deeming31-Jul-14 4:14
mveRichard Deeming31-Jul-14 4:14 
GeneralRe: Floorwise appplication Pin
Thanks787231-Jul-14 4:29
professionalThanks787231-Jul-14 4:29 
GeneralRe: Floorwise appplication Pin
VICK12-Aug-14 0:48
professional VICK12-Aug-14 0:48 
GeneralRe: Floorwise appplication Pin
PIEBALDconsult31-Jul-14 4:31
mvePIEBALDconsult31-Jul-14 4:31 
GeneralRe: Floorwise appplication Pin
Thanks787231-Jul-14 4:33
professionalThanks787231-Jul-14 4:33 
GeneralRe: Floorwise appplication Pin
PIEBALDconsult31-Jul-14 4:38
mvePIEBALDconsult31-Jul-14 4:38 
GeneralRe: Floorwise appplication Pin
Bernhard Hiller31-Jul-14 20:54
Bernhard Hiller31-Jul-14 20:54 
GeneralRe: Floorwise appplication Pin
Richard Deeming1-Aug-14 2:08
mveRichard Deeming1-Aug-14 2:08 
GeneralRe: Floorwise appplication Pin
PIEBALDconsult4-Aug-14 12:45
mvePIEBALDconsult4-Aug-14 12:45 
GeneralRe: Floorwise appplication Pin
GuyThiebaut5-Aug-14 1:51
professionalGuyThiebaut5-Aug-14 1:51 
GeneralRe: Floorwise appplication Pin
Johnny J.23-Jan-15 1:00
professionalJohnny J.23-Jan-15 1:00 
GeneralWhen the comment is longer than the code Pin
OriginalGriff30-Jul-14 5:51
mveOriginalGriff30-Jul-14 5:51 
GeneralRe: When the comment is longer than the code Pin
mcep5f200930-Jul-14 8:36
mcep5f200930-Jul-14 8:36 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.