0

I have a control derived from COleControl. When loading this control , it calls OnSize, Within OnSize I am getting ClientRect area by calling GetClientRect and moving the control to the area got from GetClientRect.

First time when initializing the GetClientRect returns sizes in right and bottom. But next time when referesh happens, GetClientRect returns the area with bottom as 0. So I couldn't able to view the control.

Is there any way to get proper Client rect area in referesh also?

Or Any idea how this client rect size determined?

srajeshnkl
  • 883
  • 3
  • 16
  • 49
  • Post some code of loading the control and for the refresh – Edward Clements Jun 01 '13 at 08:06
  • This control is loaded from another application. I don't have control to the application which is loading it. Both first time and referesh time the control constructor is getting called. It seems to be the control is created newly both scenarios. Any idea why the GetClientRect returns different values on both the times? – srajeshnkl Jun 03 '13 at 04:35
  • Sorry, cannot say without looking at the code – Edward Clements Jun 03 '13 at 07:02

0 Answers0