Quote:Original post by ajm113Right. If I had read your original post more carefully, I would have noticed that myself. :-)
Well the return value is 0 for SetWindowLong, and the value entered is 0 as well.
That's your problem. You need to be passing "this" for the last arg of CreateWindowEx. That is the value that gets passed to SetWindowLong, and which later comes out of GetWindowLong. If it isn't there, you get a NULL pointer, and the event handler is never called.
Your invisible window problem is unrelated to the "this" you're passing in. It's something else you're doing in the event handler, most likely.