2

How can I get a handle to my current window in wx.Python (hWnd) and set it's style to WS_EX_NOPARENTNOTIFY, or can I set this when I initialize the frame?

This question is a result from an answer here

Community
  • 1
  • 1
Fry
  • 4,106
  • 9
  • 38
  • 51

2 Answers2

2

Try this?

frame.SetExtraStyle(4)

Also, frame.GetHandle() will return the HWND. But this all sounds pretty hacked up.

FogleBird
  • 74,300
  • 25
  • 125
  • 131
  • Agreed, but there doesn't seem to be a way to close the window and not have the parent refuse to close later. – Fry Jun 05 '09 at 18:11
0

Try this

self.Show(True)
self.Show(False)
self.Show(True)
self.GetHandle()
  • 1
    Thank you for this code snippet, which might provide some limited, immediate help. A proper explanation [would greatly improve](//meta.stackexchange.com/q/114762) its long-term value by showing *why* this is a good solution to the problem, and would make it more useful to future readers with other, similar questions. Please [edit] your answer to add some explanation, including the assumptions you've made. – Toby Speight Dec 21 '17 at 13:09