We have a struct defined as : Then we are sent a message... And this is the code which gets the message lParam contains the address of the struct. Here we want to access to the struct. But there is a problem with the code. pWinPos is a constant pointer, so we can't simply assign an address to it. So, finally, here is my question... How can I access to the WINDOWPOS struct whose address is given by lParam PS : I am using Dev-C++
Welcome to the Programming forum. By type casting the lParam pointer to the WINDOWPOS pointer. pWinPos = (WINDOWPOS *)lParam; Thanks Shabbir Bhimani
That one works, thank you. Actually, I tried the same thing, but I put the * oparetor to the wrong place : pWinPos = (* WINDOWPOS)lParam; instead of pWinPos = (WINDOWPOS *)lParam; That is silly of me
The silly's can come at any time and if you share the knowledge and queries with other you tend to reduce them. haha