Click here to Skip to main content
15,867,453 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: Wonderful logger [modified] Pin
musefan23-Mar-11 6:23
musefan23-Mar-11 6:23 
GeneralRe: Wonderful logger Pin
Vladimir Svyatski23-Mar-11 7:41
professionalVladimir Svyatski23-Mar-11 7:41 
GeneralRe: Wonderful logger Pin
drummerboy051125-Mar-11 12:14
professionaldrummerboy051125-Mar-11 12:14 
GeneralAbout database connection, again Pin
Vladimir Svyatski15-Mar-11 0:45
professionalVladimir Svyatski15-Mar-11 0:45 
Generalhow to: minutes to hours conversion Pin
amatecki13-Mar-11 21:33
professionalamatecki13-Mar-11 21:33 
GeneralRe: how to: minutes to hours conversion Pin
Jörgen Andersson13-Mar-11 22:29
professionalJörgen Andersson13-Mar-11 22:29 
GeneralRe: how to: minutes to hours conversion Pin
Bernhard Hiller14-Mar-11 3:39
Bernhard Hiller14-Mar-11 3:39 
Generalsmart way to detect if System.Boolean true or false PinPopular
Vladimir Svyatski11-Mar-11 2:22
professionalVladimir Svyatski11-Mar-11 2:22 
I've just found an "excellent" way to detect if boolean value is true or not in C#. Just great! Important, "value" variable is System.Boolean.
string valueStr = value.ToString();
if (valueStr.Equals("true", StringComparison.CurrentCultureIgnoreCase))
{
    PDFIncludeWatermark_ = "true";
}
else
{
    PDFIncludeWatermark_ = "false";
}

GeneralRe: smart way to detect if System.Boolean true or false PinPopular
musefan11-Mar-11 2:57
musefan11-Mar-11 2:57 
GeneralRe: smart way to detect if System.Boolean true or false Pin
Luc Pattyn11-Mar-11 3:30
sitebuilderLuc Pattyn11-Mar-11 3:30 
GeneralRe: smart way to detect if System.Boolean true or false PinPopular
musefan11-Mar-11 4:14
musefan11-Mar-11 4:14 
JokeRe: smart way to detect if System.Boolean true or false Pin
AspDotNetDev11-Mar-11 9:56
protectorAspDotNetDev11-Mar-11 9:56 
GeneralRe: smart way to detect if System.Boolean true or false Pin
Paladin200011-Mar-11 3:58
Paladin200011-Mar-11 3:58 
GeneralRe: smart way to detect if System.Boolean true or false PinPopular
musefan11-Mar-11 4:15
musefan11-Mar-11 4:15 
JokeRe: smart way to detect if System.Boolean true or false Pin
Vladimir Svyatski11-Mar-11 9:13
professionalVladimir Svyatski11-Mar-11 9:13 
GeneralRe: smart way to detect if System.Boolean true or false Pin
R. Erasmus24-Mar-11 21:27
R. Erasmus24-Mar-11 21:27 
GeneralRe: smart way to detect if System.Boolean true or false PinPopular
OriginalGriff11-Mar-11 21:10
mveOriginalGriff11-Mar-11 21:10 
JokeRe: smart way to detect if System.Boolean true or false Pin
Vladimir Svyatski12-Mar-11 4:53
professionalVladimir Svyatski12-Mar-11 4:53 
GeneralRe: smart way to detect if System.Boolean true or false Pin
OriginalGriff12-Mar-11 4:59
mveOriginalGriff12-Mar-11 4:59 
NewsRe: smart way to detect if System.Boolean true or false Pin
Tallmaris15-Mar-11 0:48
Tallmaris15-Mar-11 0:48 
GeneralRe: smart way to detect if System.Boolean true or false Pin
OriginalGriff15-Mar-11 0:52
mveOriginalGriff15-Mar-11 0:52 
GeneralRe: smart way to detect if System.Boolean true or false Pin
Tallmaris15-Mar-11 1:23
Tallmaris15-Mar-11 1:23 
GeneralRe: smart way to detect if System.Boolean true or false Pin
OriginalGriff15-Mar-11 1:27
mveOriginalGriff15-Mar-11 1:27 
GeneralRe: smart way to detect if System.Boolean true or false Pin
Rick Shaub15-Mar-11 7:51
Rick Shaub15-Mar-11 7:51 
GeneralRe: smart way to detect if System.Boolean true or false Pin
Bernhard Hiller14-Mar-11 3:50
Bernhard Hiller14-Mar-11 3:50 

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.