[Originally posted by angiras]

I have created a class :

----------------------------------

  Public Class menu : Inherits MainMenu

Sub New()
  MyBase.new()
  Dim sItem As String
  For Each sItem In listItems()
Me.MenuItems.Add(sItem)
  Next
End Sub

Private Function listItems() As StringCollection

  Dim sc As New StringCollection

  sc.Add("file")
  sc.Add("parameters")
  sc.Add("help")

  Return sc

End Function

  End Class

----------------------------------

I want on each winForm this menu :

----------------------------------


Private mnu As New angiras.menu

Private Sub mainForm_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Me.Controls.Add(mnu)
  End Sub


----------------------------------

it doesn't work

how can I add my menu into a winform ?

thank you