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: Let's "switch" to Something Else PinmemberMartin081510-Apr-13 2:41 
GeneralThings that make you go WTF... PinmemberGary Wheeler1-Apr-13 2:32 
GeneralRe: Things that make you go WTF... PinmemberMatt T Heffron1-Apr-13 9:53 
GeneralRe: Things that make you go WTF... PinmemberGary Wheeler1-Apr-13 9:59 
GeneralRe: Things that make you go WTF... PinprofessionalBrisingr Aerowing1-Apr-13 10:48 
GeneralRe: Things that make you go WTF... PinprotectorPete O'Hanlon2-Apr-13 8:17 
GeneralRe: Things that make you go WTF... PinmemberGary Wheeler2-Apr-13 8:25 
GeneralRe: Things that make you go WTF... [modified] Pinmemberpatbob2-Apr-13 6:49 
Given you said it was replicated in multiple places, I can see only one possible perceived value -- to block this function from returning until after the dispatcher thread is finished executing something else. Such behavior isn't guaranteed, but it would work just often enough that I can easily see someone clueless thinking it does. Before totally writing it off, I'd look carefully at what's done with the dispatcher prior to executing this code.
 
As pointed out, this only makes sense if its run with an Invoke, instead of the BeginInvoke that's being used. Nevermind Frown | :(
We can program with only 1's, but if all you've got are zeros, you've got nothing.


modified 2-Apr-13 14:09pm.

GeneralRe: Things that make you go WTF... PinmemberGary Wheeler2-Apr-13 7:38 
GeneralRe: Things that make you go WTF... Pinmemberpatbob2-Apr-13 9:03 
JokeRe: Things that make you go WTF... PinmemberRafagaX2-Apr-13 7:50 
GeneralRe: Things that make you go WTF... PinprotectorAspDotNetDev2-Apr-13 9:11 
GeneralRe: Things that make you go WTF... PinmemberGary Wheeler2-Apr-13 9:24 
GeneralRe: Things that make you go WTF... PinmemberBobJanova4-Apr-13 0:29 
GeneralRe: Things that make you go WTF... PinmemberGary Wheeler4-Apr-13 1:44 
GeneralThat was weird... PinmemberBrisingr Aerowing28-Mar-13 8:57 
GeneralRe: That was weird... PinmemberJulien Villers8-Apr-13 6:10 
GeneralRe: That was weird... PinprofessionalBrisingr Aerowing8-Apr-13 15:06 
GeneralExternal System's Table's View's Table's View ('s Tables?) PinprotectorAspDotNetDev26-Mar-13 13:38 
GeneralRe: External System's Table's View's Table's View ('s Tables?) PinprofessionalBrisingr Aerowing5-Apr-13 6:16 
GeneralFound this a few minutes ago PinmemberSomeGuyThatIsMe26-Mar-13 11:51 
GeneralRe: Found this a few minutes ago PinmemberJan Steyn28-Mar-13 1:56 
GeneralRe: Found this a few minutes ago PinmemberSomeGuyThatIsMe28-Mar-13 4:34 
GeneralRe: Found this a few minutes ago Pinmemberagolddog29-Mar-13 4:39 
GeneralRe: Found this a few minutes ago PinmemberLeng Vang29-Mar-13 7:35 

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.141220.1 | Last Updated 21 Dec 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid