Click here to Skip to main content

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, embarrasing 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: Try/catch block... PinmemberReese Currie21-Nov-12 3:52 
GeneralRe: Try/catch block... Pinmemberbkebamc21-Nov-12 6:17 
GeneralRe: Try/catch block... PinmemberH.Brydon21-Nov-12 17:34 
GeneralRe: Try/catch block... PinmemberBernhard Hiller21-Nov-12 21:27 
GeneralRe: Try/catch block... Pinmemberlukeer22-Nov-12 22:06 
GeneralRe: Try/catch block... PinmemberKP Lee26-Nov-12 8:41 
GeneralRe: Try/catch block... PinmemberGary R. Wheeler21-Nov-12 5:26 
GeneralRe: Try/catch block... PinmemberPhilLenoir21-Nov-12 7:36 
Quitter - use recursion!
public string ReadFile(string filename)
{
     try
     {
          return File.ReadAllText(filename);
     }
     catch
     {
          return ReadFile(filename);
     }
}
Life is like a s**t sandwich; the more bread you have, the less s**t you eat.

GeneralRe: Try/catch block... PinmemberZac Greve27-Nov-12 9:24 
GeneralRe: Try/catch block... PinmemberMember 771191721-Nov-12 10:12 
GeneralRe: Try/catch block... Pinmemberkakan28-Nov-12 1:46 
GeneralRe: Try/catch block... PinmemberPIEBALDconsult20-Nov-12 14:30 
GeneralRe: Try/catch block... Pinmemberjasperp20-Nov-12 21:56 
GeneralRe: Try/catch block... Pinmemberspencepk21-Nov-12 5:03 
GeneralRe: Try/catch block... PinmemberProgramFOX21-Nov-12 5:10 
GeneralRe: Try/catch block... PinmemberRafagaX21-Nov-12 5:28 
GeneralRe: Try/catch block... PinmemberProgramFOX21-Nov-12 5:32 
GeneralRe: Try/catch block... Pinmemberjnlt21-Nov-12 6:33 
GeneralWhy would you do this to a stored procedure? It never did anything to you. Pinmemberthrakazog15-Nov-12 12:58 
GeneralRe: Why would you do this to a stored procedure? It never did anything to you. PinmemberZac Greve15-Nov-12 13:48 
GeneralRe: Why would you do this to a stored procedure? It never did anything to you. Pinmemberjim lahey20-Nov-12 4:41 
JokeRe: Why would you do this to a stored procedure? It never did anything to you. PinmemberLewis198620-Nov-12 21:50 
GeneralRe: Why would you do this to a stored procedure? It never did anything to you. PinprotectorPete O'Hanlon20-Nov-12 13:09 
GeneralRe: Why would you do this to a stored procedure? It never did anything to you. PinmemberFlorin Jurcovici22-Nov-12 2:13 
GeneralRe: Why would you do this to a stored procedure? It never did anything to you. PinmemberSomeGuyThatIsMe21-Nov-12 3:17 

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

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


Advertise | Privacy | Mobile
Web04 | 2.8.150302.1 | Last Updated 5 Mar 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid