Creat a new class named Class1, it's codes like this:
Public Event MyEvent()
Public Sub RaiseTheEvent()
'some other codes here
Create a new form, draw a command on it named Command1, double the command to open the code.
It codes like this:
Private WithEvents Myclass As class1
Private Sub Command1_Click()
Set Myclass = New class1
Call Myclass.RaiseTheEvent 'In this sub event is raised.
Private Sub Myclass_MyEvent()'this is the sub to dill with the event.
MsgBox "class1's event occured."
Start the application and Click the button will raise the event.