How to specify both <EventClass> and <Guid> Attributes on a class

  • Thread starter Thread starter MikeL
  • Start date Start date
M

MikeL

What is the syntax for declaring both <EventClass> and <Guid> attributes on
a class? The following causes an error in the class declaration:

Imports System.Runtime.InteropServices
Imports System.EnterpriseServices

<Guid("0EA77155-29EA-4f1b-870C-B6D7287E65EC")> _
Public Interface IMyEventClass

End Interface

' Below is the problem:

<EventClass()> _
<Guid("E07B09A3-15C6-400a-BD7E-FDAFEF78BC2C")> _
Public Class MyEventClass
Inherits ServicedComponent
Implements IMyEventClass
End Class


Thanks in advance,

Mike
 
Nevermind, I found the answer:

<EventClass(), _
Guid(".....")> _
Public Class ...

End Class
 
Back
Top