G
Guest
Hi,
In a VS2005 app with VB.NET.
In a mdi child window I open a messagebox to ask a confirmation from the
user. After the user clicks on the yes or no button, the main application is
hidden behind all other open application windows.
this is the messagebox statement:
If MessageBox.Show(String.Format(Me.lblConfirmDelete.Text, Me.Text,
Id.ToString), "Delete", _
MessageBoxButtons.YesNo, MessageBoxIcon.Question,
MessageBoxDefaultButton.Button1, _
MessageBoxOptions.DefaultDesktopOnly, False) =
Windows.Forms.DialogResult.Yes Then
Return True
End If
The function is called from a button click event on the mdi child windows
form, that form had the focus.
Does anyone know how to give the focus back to the mdi child window, i.e. to
my application?
--
Jan D''Hondt
Jade bvba
Belgium
Database and .NET development
<Toto, I''ve got a feeling we''re not in Kansas anymore.>
In a VS2005 app with VB.NET.
In a mdi child window I open a messagebox to ask a confirmation from the
user. After the user clicks on the yes or no button, the main application is
hidden behind all other open application windows.
this is the messagebox statement:
If MessageBox.Show(String.Format(Me.lblConfirmDelete.Text, Me.Text,
Id.ToString), "Delete", _
MessageBoxButtons.YesNo, MessageBoxIcon.Question,
MessageBoxDefaultButton.Button1, _
MessageBoxOptions.DefaultDesktopOnly, False) =
Windows.Forms.DialogResult.Yes Then
Return True
End If
The function is called from a button click event on the mdi child windows
form, that form had the focus.
Does anyone know how to give the focus back to the mdi child window, i.e. to
my application?
--
Jan D''Hondt
Jade bvba
Belgium
Database and .NET development
<Toto, I''ve got a feeling we''re not in Kansas anymore.>