Run attached VSTA macro

Is it possible to run VSTA macro, which is attached in the design binder, from a second VBA macro, using the RunAttachedMacro method?

Since the RunAttachedMacro takes the macro name, module name, and procedure name as parameters, I tried setting up my vsta macro like this:

Partial Class SolidWorksMacro
Public Sub main()

    MsgBox("To dela")
End Sub
''' <summary>
''' The SldWorks swApp variable is pre-assigned for you.
''' </summary>
Public swApp As SldWorks

End Class

Module HandlerModule
Dim macro As New SolidWorksMacro

Public Sub main()

End Sub

End Module

Unfortunatly unsuccessful.

Posnetek zaslona 2024-05-31 212911