Código:
  
Entonces en mi formulario principal hago una prueba llamando directamente el método así:Public Function GenerarMenu(ByVal flag As Boolean, ByVal usuario As String, ByVal ip As Integer, ByVal opc As MainMenu.MenuItemCollection) As System.Windows.Forms.MainMenu
        Dim tabla As DataTable
        Dim mMenu As MenuItem
        If flag = True Then
           tabla = ObOp.Consultar("select idopc, cnomopc,caccion,cdescripcion from menu where cgrp='admin'))")
        End If
        Dim dvArbol As DataView
        dvArbol = New DataView(tabla)
        dvArbol.RowFilter = tabla.Columns(3).ColumnName + "=" + ip.ToString
        For Each dractual As DataRowView In dvArbol
            Dim t As New MenuItem
            t.Name = dractual.Item(0)
            t.Text = dractual.Item(1)
            t.Tag = dractual.Item(2)
            If opc Is Nothing Then
                mMenu.MenuItems.Add(t)
            Else
                opc.Add(t)
                AddHandler t.Click, AddressOf opciones_click
            End If
            GenerarMenu(False, usuario, t.Name, t.MenuItems)
        Next dractual
        Return GenerarMenu
    End Function
 Private Sub opciones_click(ByVal sender As Object, ByVal e As System.EventArgs)
        Dim t As MenuItem
        t = CType(sender, MenuItem)
        Dim formulario As New Form
        Dim tipo As System.Type
        If t.Text = "sasSalir" Then
            form_login.Close()
        Else
            Try
                tipo = Type.GetType("ADUS." & t.Tag)
                formulario.Show()
            Catch ex As Exception
                MessageBox.Show("El programa no existe")
            End Try
        End If
    End Sub
Código:
  
Mi formulario es este:Call mUsr.GenerarMenu(True, 1, 1, Nothing)
Código:
  
Pero al ejecutarlo el formulario no me muestra el menú debo hacer algo mas? tienen algún ejemplito. Gracias! Public Class MenuUsuario
    Inherits System.Windows.Forms.Form
    Public usuario As String
    Private mUsr As New clsClasedeArriba
    Private Sub Menu_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        If usuario Is Nothing Then
            'vacio
        Else
            'Probando el numero 1
            Call mUsr.GenerarMenu(True, 1, 1, Nothing)
        End If
    End Sub
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Me.Close()
        form_login.Close()
    End Sub
End Class
 

