Salve,
creo un CommandButton da codice così:
Poi faccio la funzione dell'evento del click del mouse:codice:Dim button As CommandButton Set button = nomeform.Controls.Add("Vb.CommandButton", "button") With button .Caption = "Annulla" .Width = w * 0.1 .Height = h * 0.05 .Top = menuAmministrazione.Height + (h * 0.84) .Left = menuLido.Width + (w * 0.4) .Visible = True End With
Ma l'evnto del click() non viene richiamato, cosa potrebbe essere?codice:Private Sub button_Click() MsgBox "Cliccato" End Sub
Grazie