Drag an Drop in MDI child forms

T

Torsten Zachert

Hi,

I have to Drag an Drop data between 2 listviews in MDI child forms. How do I
activate the target child form, if the mouse is over.

Tia

Torsten
 
M

Martin Stainsby

Torsten Zachert said:
Hi,

I have to Drag an Drop data between 2 listviews in MDI child forms. How do
I
activate the target child form, if the mouse is over.

Tia

Torsten


using System.Runtime.InteropServices;

[DllImport ("user32.dll")]
public static extern int SendMessage(IntPtr hWnd, int Msg, int wParam, int
lParam);

private const int WM_NCACTIVATE = 0x0086;


// to activate
SendMessage(Child.Handle, WM_NCACTIVATE, 1, 0);

// to deactivate
SendMessage(Child.Handle, WM_NCACTIVATE, 0, 0);



there's also a select property, that's not intended for use from "your"
code.

Child.Select();

Maybe someone knows why it's not intended from "your" code?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

MDI Forms using MainMenu 1
Main window location 4
mdi child detach reattach problem 2
MDI and Reflection 2
MDI Forms - Child Forms 4
MDI Behaviour 2
(Re)opening closed MDI child? 2
Q: Newbe quiz. MDI Forms... 2

Top