.net error: Implementing property must have matching 'ReadOnly' or 'WriteOnly' specifiers

I'm getting this error when trying to implement an interface in vb.net:

Public Interface IFoo
   ReadOnly Property Foo() As String
End Interface

Public Class myFoo
  Implements IFoo

  Public ReadOnly Property Foo() As String
     Get
       return "Foo"
     End Get
  End Property
...
End Class

What is missing?

9
задан chris 9 March 2011 в 17:29
поделиться