i am tryng to move a rectangle placed in CStatic object, the CStatic object is in a child window of the application.every time i move (on LButton Up)the rect it goes out of the CStatic object and goes to the corner of the client screen. I want it to remain within that CStatic object(rectangle)but it just flies out please help me. currently i m moving it with the help of SetWindowPos();
Should i get the coordinates of the CStatic object, then what???
You need to have an instance of the class to be able to have its address. In your example, RUNTIME_CLASS is used to get informations about the class (and not a specific instance !) of the class. It returns a structure containing info about your class (its name, the size, ...)
There should be another way to get the object you try to access. If you could describe the situation you have more in detail, that could help a lot.
I am trying to get the OnProgress status using URLDownloadToFile. For this, I need a callback for the IBindStatusCallback interface. So, I created a thread AfxBeginThread ( downloadFile, this, THREAD_PRIORITY_NORMAL, 0, 0) that just calls the WorkerThreadProc.