title: Why won't this C# convert to VB?
body: <p>I'm trying to convert the below bit of code into VB (and obviously apply it to my own solution) that I took from <a href="http://msdn.microsoft.com/en-us/library/hy3sefw3%28VS.80%29.aspx" rel="nofollow noreferrer">this MSDN article</a></p>
  
  <pre><code>// The event. Note that by using the generic EventHandler&lt;T&gt; event type
  // we do not need to declare a separate delegate type.
  public event EventHandler&lt;ShapeEventArgs&gt; ShapeChanged;
  
  //The event-invoking method that derived classes can override.
  protected virtual void OnShapeChanged(ShapeEventArgs e)
  {
      // Make a temporary copy of the event to avoid possibility of
      // a race condition if the last subscriber unsubscribes
      // immediately after the null check and before the event is raised.
      EventHandler&lt;ShapeEventArgs&gt; handler = ShapeChanged;
      if (handler != null)
      {
          handler(this, e);
      }
  }
  </code></pre>
  
  <p>My conversion (applicable to my program) is as follows:</p>
  
  <pre><code>Public Event StatusChanged As EventHandler(Of StatusChangedArgs)
  
  Protected Overridable Sub OnStatusChanged(ByVal e As StatusChangedArgs)
     Dim handler As EventHandler(Of StatusChangedArgs) = StatusChanged 'error here'
     RaiseEvent handler(Me, e)
  End Sub
  </code></pre>
  
  <p>But I'm getting an error: <code>Public Event StatusChanged(sender As Object, e As StatusChangedArgs) is an event and cannot be called directly. Use a "RaiseEvent" statement to raise an event.</code> If I'm converting it correctly, this doesn't make sense, since it's copied right out of MSDN, who I think would be correct, so obviously I'm doing something wrong. Anyone have any ideas?</p>
  
  <p>Thanks...</p>