Browse by Tags

Tagged Content List
  • Blog Post: Spot the Bug! – Is it in VB or XAML? (Jonathan Aneja)

    What’s wrong with the following WPF code? Class Window1 Sub OK_Click(sender As Object , e As RoutedEventArgs) Handles OK.Click MsgBox( "Button Clicked" ) End Sub End Class < Window x : Class ="Window1" xmlns ="http://schemas.microsoft.com/winfx/2006/xaml/presentation...
  • Blog Post: Spot the Bug! – Much ado about Nothing… Part 2! (Jonathan Aneja)

    In yesterday’s post we saw that the use of the wrong comparison operator with Nothing in an If block can lead to surprising results. Let’s look at a slightly different case today: Dim x As Integer = Nothing If x = Nothing Then MsgBox( "A true statement - we land here" ) Else MsgBox...
  • Blog Post: Spot the Bug! – Much Ado about Nothing… (Jonathan Aneja)

    Microsoft has this neat mailing list called “Spot the Bug” where developers can send interesting snippets of code that look correct but actually have subtle bugs in them. The puzzles are a lot of fun and I’ve always thought it’d be a fun thing to try here on the team blog. Over the past year or so I...
Page 1 of 1 (3 items)