Buenas,
tengo que traducir esto a VB. He probado con un traductor online, pero no me lo acaba de pillar en VB. A ver si alguien me puede echar un calbe
Código:
if(_frm != null) {
_frm.KeyPress -= new KeyPressEventHandler(this.event_KeyPress);
_frm.MouseDown -= new MouseEventHandler(this.event_MouseDown);
foreach(Control _ctl in _frm.Controls) {
_ctl.KeyPress -= new KeyPressEventHandler(this.event_KeyPress);
_ctl.MouseDown -= new MouseEventHandler(this.event_MouseDown);
}
yo lo tengo así, y lo que está en rojo está c omo "error".
Cita: If Not (_frm Is Nothing) Then
_frm.KeyPress -= New KeyPressEventHandler(Me.event_KeyPress)
_frm.MouseDown -= New MouseEventHandler(Me.event_MouseDown)
Dim _ctl As Control
For Each _ctl In _frm.Controls
_ctl.KeyPress -= New KeyPressEventHandler(Me.event_KeyPress)
_ctl.MouseDown -= New MouseEventHandler(Me.event_MouseDown)
Next _ctl
End If
saludos