My parent window lost the focus
Posted: Wed Mar 17, 2004 5:06 pm
Hello,
I have a problem with my parent window.
It lost the focus when i use the child window.
I hope to make parent window which keep focus when i use child window.
Thanks for your help. And excuse me for mistakes
I have a problem with my parent window.
It lost the focus when i use the child window.
Code: Select all
WindowE = GetForegroundWindow_()
OpenWindow(0, 200, 200, 500, 500, #PB_Window_SystemMenu | #PB_Window_MinimizeGadget | #PB_Window_MaximizeGadget | #PB_Window_SizeGadget | #WS_CLIPCHILDREN, "Options")
SetParent_(WindowE, WindowID())
SetWindowLong_(WindowE, #GWL_EXSTYLE, GetWindowLong_(WindowE, #GWL_EXSTYLE) | #WS_EX_MDICHILD)
; SetWindowLong_(WindowE, #GWL_STYLE, GetWindowLong_(WindowE, #GWL_STYLE) | #WS_CHILD)
MoveWindow_(WindowE, 0, 0, 400, 400, 1)
Repeat
Event = WaitWindowEvent()
Until Event = #WM_CLOSE
; SetWindowLong_(WindowE, #GWL_STYLE, GetWindowLong_(WindowE, #GWL_STYLE) ! #WS_CHILD)
SetWindowLong_(WindowE, #GWL_EXSTYLE, GetWindowLong_(WindowE, #GWL_EXSTYLE) ! #WS_EX_MDICHILD)
SetParent_(WindowE, 0)Thanks for your help. And excuse me for mistakes